@@ -399,6 +399,58 @@ When a custom directory is used, bashunit writes `BASHUNIT_BOOTSTRAP=<dir>/boots
399399```
400400:::
401401
402+ ## Learn
403+
404+ > ` bashunit --learn `
405+
406+ Starts an interactive learning tutorial that teaches you how to use bashunit step by step through hands-on exercises.
407+
408+ The tutorial covers:
409+ - Writing your first test
410+ - Using different assertions
411+ - Setup and teardown functions
412+ - Testing functions and scripts
413+ - Mocking external dependencies
414+ - Using spies to verify calls
415+ - Parameterized testing with data providers
416+ - Testing exit codes
417+ - A complete real-world challenge
418+
419+ Your progress is saved automatically, and you can resume at any time.
420+
421+ ::: code-group
422+ ``` bash [Example]
423+ ./bashunit --learn
424+ ```
425+ ``` [Output]
426+ bashunit - Interactive Learning
427+
428+ Choose a lesson:
429+
430+ 1. Basics - Your First Test
431+ 2. Assertions - Testing Different Conditions
432+ 3. Setup & Teardown - Managing Test Lifecycle
433+ 4. Testing Functions - Unit Testing Patterns
434+ 5. Testing Scripts - Integration Testing
435+ 6. Mocking - Test Doubles and Mocks
436+ 7. Spies - Verifying Function Calls
437+ 8. Data Providers - Parameterized Tests
438+ 9. Exit Codes - Testing Success and Failure
439+ 10. Complete Challenge - Real World Scenario
440+
441+ p. Show Progress
442+ r. Reset Progress
443+ q. Quit
444+
445+ Enter your choice:
446+ ```
447+ :::
448+
449+ ::: tip
450+ The learn mode is perfect for new users getting started with bashunit.
451+ It provides practical, hands-on experience with immediate feedback.
452+ :::
453+
402454## Help
403455
404456> ` bashunit --help `
0 commit comments