Closed hughsaunders closed 5 years ago
Review notes:
This looks great @hughsaunders! I didn't realize (my ignorance) there were decent tools for testing Shell scripts.
15:31 $ git diff --stat review_round_1 review_round_2_no_subtrees
.gitmodules | 9 ----
.gittrees | 13 +++++
Jenkinsfile | 18 +++----
README.md | 135 +++++++++++++++++++++++-----------------------
filehandling/{lib.sh => lib} | 4 +-
git/lib | 79 +++++++++++++++++++++++++++
git/lib.sh | 13 -----
helpers/lib | 20 +++++++
helpers/lib.sh | 18 -------
init.sh => init | 18 +++----
k8s/Dockerfile | 38 ++++++++-----
k8s/{lib.sh => lib} | 16 +++---
k8s/{platform_login.sh => platform_login} | 4 ++
logging/{lib.sh => lib} | 2 +-
run-tests | 16 ++++++
run-tests.sh | 13 -----
test-utils/bats | 1 -
test-utils/bats-assert-1 | 1 -
test-utils/bats-support | 1 -
test-utils/{lib.sh => lib} | 25 +++++----
test-utils/tap2junit/Dockerfile | 9 ++--
test-utils/tap2junit/tap2junit.py | 22 ++++----
tests-for-this-repo/filehandling.bats | 6 +--
tests-for-this-repo/git.bats | 138 ++++++++++++++++++++++++++++++++++++++++++------
tests-for-this-repo/helpers.bats | 12 ++---
tests-for-this-repo/k8s.bats | 6 +--
tests-for-this-repo/lint.bats | 81 +++++++++++++---------------
tests-for-this-repo/logging.bats | 6 +--
tests-for-this-repo/python-lint.sh | 18 -------
tests-for-this-repo/python-lint/Dockerfile | 9 ++--
tests-for-this-repo/{run-bats-tests.sh => run-bats-tests} | 41 ++++++++------
tests-for-this-repo/run-gitleaks | 18 +++++++
tests-for-this-repo/run-python-lint | 20 +++++++
tests-for-this-repo/test-utils.bats | 79 ++++++++++++++-------------
34 files changed, 567 insertions(+), 342 deletions(-)
@dividedmind When you get a chance, can you go through this PR (it's pretty bulky though) and this comment to see what items seem worth addressing in a followup PR from @hughsaunders?
This commit adds the structure of the libraries and a few funcions. Most of the code in this commit is geared towards making sure this repo stays tested and documented in future.
The following things are checked:
See Readme for a list of the functions that are included, and for more information on testing with BATS.