Skip to content

Commit

Permalink
fix self test
Browse files Browse the repository at this point in the history
  • Loading branch information
SaswatPadhi committed Oct 2, 2024
1 parent 4d7e924 commit fcce27e
Show file tree
Hide file tree
Showing 7 changed files with 8 additions and 49 deletions.
3 changes: 2 additions & 1 deletion .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -8,4 +8,5 @@
*/data
*/generated

test__*
test__*
_.test.*
10 changes: 6 additions & 4 deletions _scripts/test_comp.sh
Original file line number Diff line number Diff line change
Expand Up @@ -237,14 +237,14 @@ SETUP "stopping $TARGET_COMP_1_DISPLAY & $TARGET_COMP_2_DISPLAY without options"
CHECK $'grep -Pqs "Container $TARGET_COMP_1.* Removed" "$COMP_ERR_PATH"' \
"Stopped $TARGET_COMP_1_DISPLAY successfully" \
exit_on_failure
CHECK $'grep -qs "No resource found to remove for project \\\\\\\\\\"$TARGET_COMP_2\\\\\\\\\\"" "$COMP_ERR_PATH"' \
CHECK $'grep -Pqs "No resource found to remove for project .*$TARGET_COMP_2" "$COMP_ERR_PATH"' \
"Nothing to remove reported for $TARGET_COMP_2_DISPLAY" \
exit_on_failure
CHECK $'[ $COMP_EXIT_CODE -eq 0 ]' \
"EXIT_CODE = 0" \
exit_on_failure

_INIT tang _ .bad.name_
_INIT tang _.test.very_ .bad.name_

SETUP "starting $TARGET_COMP_3_DISPLAY" \
"up -P $TARGET_COMP_3"
Expand All @@ -256,6 +256,8 @@ CHECK $'[ $COMP_EXIT_CODE -eq 0 ]' \
"EXIT_CODE = 0" \
exit_on_failure

_WAIT 30s "$TARGET_COMP_3_DISPLAY to start up and emit health status"

SETUP "that status reports $TARGET_COMP_3_DISPLAY is healthy" \
"status -P $TARGET_COMP_3"
CHECK $'grep -qs "drops all \'\.\' from project name" "$COMP_ERR_PATH"' \
Expand All @@ -265,7 +267,7 @@ CHECK $'grep -qs "drops leading \'_\' from project name" "$COMP_ERR_PATH"' \
CHECK $'grep -qs "Guessing project name to be" "$COMP_ERR_PATH"' \
"Best-effort guess for project name"
CHECK $'[ $COMP_EXIT_CODE -eq 0 ]' \
"EXIT_CODE = 0; best-effort guess works (for now)" \
"EXIT_CODE = 0; best-effort guess works for now" \
exit_on_failure

SETUP "stopping & cleaning $TARGET_COMP_3_DISPLAY" \
Expand All @@ -277,7 +279,7 @@ CHECK $'grep -qs "drops leading \'_\' from project name" "$COMP_ERR_PATH"' \
CHECK $'grep -qs "Guessing project name to be" "$COMP_ERR_PATH"' \
"Best-effort guess for project name"
CHECK $'[ $COMP_EXIT_CODE -eq 0 ]' \
"EXIT_CODE = 0; best-effort guess works (for now)" \
"EXIT_CODE = 0; best-effort guess works for now" \
exit_on_failure

FINAL
8 changes: 0 additions & 8 deletions _test__3__tang__.bad.name_/docker-compose.labels.yml

This file was deleted.

6 changes: 0 additions & 6 deletions _test__3__tang__.bad.name_/docker-compose.logging.yml

This file was deleted.

8 changes: 0 additions & 8 deletions _test__3__tang__.bad.name_/docker-compose.pre_hook.sh

This file was deleted.

21 changes: 0 additions & 21 deletions _test__3__tang__.bad.name_/docker-compose.yml

This file was deleted.

1 change: 0 additions & 1 deletion _test__3__tang__.bad.name_/pre.reqs

This file was deleted.

0 comments on commit fcce27e

Please sign in to comment.