Release 0.28.0
🔧 New features
Subcommand-based CLI architecture
bashunit now groups commands by task:
bash
bashunit test [path] # Run tests (default)
bashunit bench [path] # Run benchmarks
bashunit doc [filter] # Show assertion documentation
bashunit init [dir] # Initialize a new project
bashunit learn # Interactive tutorial
bashunit upgrade # Upgrade to latest versionThe previous flags (--bench, --doc, --init, --learn, --upgrade) continue to work for backward compatibility.
Inline filter syntax
Run specific tests directly from the command line using the new inline filter syntax:
bash
bashunit tests/example_test.sh::test_my_functionbash
bashunit tests/example_test.sh:42Stop at first assertion failure
Tests now stop at the first assertion failure by default, matching the behavior of PHPUnit and Jest. This prevents later assertions from producing cascading failures.
If you prefer to run all assertions regardless of failures, use the new --run-all flag or set BASHUNIT_STOP_ON_ASSERTION_FAILURE=false.
Display skipped and incomplete tests
New options to display skipped and incomplete tests at the end of the test run:
bash
bashunit --show-skipped tests/
bashunit --show-incomplete tests/🐛 Bug fixes
- Stop executing remaining commands in
set_up/tear_downafter first failure - Count all tests as failed when
set_up_before_scriptfails - Fixed acceptance tests forcing not showing skipped and incomplete tests
🌾 Miscellaneous
- Optimize assertion guard: use integer comparison instead of string comparison
- Optimize string operations with
str::strip_ansirefactoring
See the full changelog on GitHub