Skip to content
This repository has been archived by the owner on Jan 31, 2020. It is now read-only.

Bashellite lacks proper unit testing #23

Open
codrcodz opened this issue Apr 16, 2018 · 1 comment
Open

Bashellite lacks proper unit testing #23

codrcodz opened this issue Apr 16, 2018 · 1 comment
Assignees
Labels

Comments

@codrcodz
Copy link
Member

Since bashellite is written using a hybrid of declarative/functional programming paradigms, it lacks the ability to easily integrate and write unit tests.

Proposed solution to correct this is three fold:

  1. Rewrite each individual function/subroutine to set local variables only and echo one return value per function. Ensure all code lives in a function. Ensure global variables are limited to read-only constants.
  2. Rewrite the main function to store and pipe output from one function to another.
  3. Source bash-test or assert.sh and write tests for each isolated function.
@codrcodz codrcodz self-assigned this Apr 16, 2018
@codrcodz codrcodz added the bug label Apr 16, 2018
@codrcodz codrcodz added this to the Full Code Coverage milestone May 7, 2018
@codrcodz
Copy link
Member Author

The util-libs now have near 100% code coverage thanks to #40
Still need to do the same thing for bashellite-libs.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
Projects
None yet
Development

No branches or pull requests

1 participant