test: add functional tests for the alias/install-menu logic bugs - #12
Merged
Conversation
The prior syntax + shellcheck checks couldn't have caught any of the path/shell-detection bugs fixed in the last commit, since they're all logic errors, not syntax errors. Add sandboxed functional tests instead: - tests/lib.sh: shared sandbox/assertion helpers, incl. run_as_bash/ run_as_zsh which spawn scripts with a genuine bash or zsh parent process so the scripts' own shell-detection heuristics see the shell we intend to test - test_install_aliases.sh: __PERSONAL_UTILS_DIR__ placeholder resolves to the real repo path, and re-running doesn't duplicate aliases - test_persist_env.sh: variables land in .bashrc under bash and .zshrc under zsh (not always .bashrc), and declining an overwrite prompt leaves the existing value untouched - test_install_menu.sh: install.sh's menu no longer errors on the removed gcloud/ dir and still discovers tools/gcloud.sh; static regression guards for the airbyte.sh path fix and pipefail additions make test now runs every tests/test_*.sh, and .github/workflows/test.yml picks these up automatically since it already runs make lint && make test.
test: add functional tests for the alias/install-menu logic bugs
2 tasks
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Brings the functional test suite (merged into this branch via #11) into master. The bugfix itself (#10) is already on master — this PR only adds the new commit:
make testnow runs every tests/test_*.shTest plan
🤖 Generated with Claude Code