-
-
Notifications
You must be signed in to change notification settings - Fork 28
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add support for Alpine (Linux Distro) #331
Add support for Alpine (Linux Distro) #331
Conversation
b3f1fb6
to
8661836
Compare
930bc47
to
306c935
Compare
306c935
to
58de4e2
Compare
Thanks for approving the test runs. It has now reached the first error for Alpine that I intend to fix in other pull request. Let me know what you think should be done next. I can remove the Github action and re-add it at a later time when Alpine test pass. |
This will redirect the debug option to a file, which makes debugging much easier. Eg: ./bashunit local/example_test.sh --debug local/debug.sh
3f0270d
to
9087bef
Compare
13af70a
to
3a70464
Compare
3a70464
to
e70da26
Compare
@skinner-m-c, please check the changes and let me know your thoughts. I plan to merge it today :) |
14bc969
to
6aefdd5
Compare
6aefdd5
to
9e6d625
Compare
if [[ "$_OS" == "Windows" ]]; then | ||
if [[ "$_OS" == "Windows" || $_DISTRO = "Alpine" ]]; then |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I got these tests/unit/directory_test.sh
failing on Alpine for some reason (directory permissions), but I don't know how to solve them now, so I'd better skip them for now, and work on them in another iteration/PR
# Running these tests without ` || $_DISTRO = "Alpine"`:
docker run --rm -it -v "$(pwd)":/project -w /project alpine:latest \
sh -c "apk add bash make shellcheck git curl perl && ./bashunit tests/unit/directory_test.sh"
📚 Description
Add automation for running Bashunit tests in Alpine locally and with Github actions.
🔖 Changes
Adds a target in the Makefile for running tests in Alpine. There are other approaches that could be done (e.g. entirely in Github actions, but that would make contributors unable to test changes in Alpine locally without additional work).
This change does not include fixes for running tests in Alpine. I do have some fixes that I was going to do in a separate pull request because they are a bit involved.
There are several ways to implement this kind of testing. Let me know if there is a preferred approach.
This automation does fail because
bashunit
does not currently pass in Alpine. Because this change will cause builds to fail, I recommend commenting or excluding out the Github action changes for running these tests and uncomment or add them back when the Alpine test pass. I have included the Github action for sake of completion.✅ To-do list
CHANGELOG.md
to reflect the new feature or fix