Skip to content

test: add comprehensive isolated functional test suite and harden toolbox CLI - #33

Merged
ashishsinghbora merged 2 commits into
mainfrom
test/functional-test-suite
Sep 24, 2026
Merged

ashishsinghbora merged 2 commits into
mainfrom
test/functional-test-suite

Conversation

@ashishsinghbora

Copy link
Copy Markdown
Owner

Summary

Tests

  • Added tests/functional_test.sh providing 53 isolated behavioural and security assertions across all script categories.
  • Covers path traversal and absolute path blocking, backup exclusion of destination directory, file organizer collisions/symlink handling, mock package managers (pacman, apt, dnf, zypper, apk), safe process termination, and SSH key generation/backup.
  • Integrated tests/functional_test.sh into tests/test_all.sh for automated execution.

Enhancements & Bug Fixes Discovered by Test Suite

  • bin/linux-toolbox: added CLI subcommands (list, run, and direct script name execution) while preserving the interactive keyboard menu.
  • scripts/process/process-info.sh: added PID existence checking and status reporting, process name searching via pgrep, user filtering, and top CPU/memory summaries.
  • scripts/storage/directory-size.sh: supported -d / --dir flags in addition to positional arguments.
  • scripts/system/kernel-info.sh: fixed SIGPIPE (exit 141) in zcat /proc/config.gz | head pipeline under pipefail.

Verification

  • Verified all 53 functional tests pass cleanly.
  • Verified ShellCheck passes without warnings.
  • Verified tests/test_all.sh completes with 0 errors.

@ashishsinghbora ashishsinghbora left a comment

Copy link
Copy Markdown
Owner Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Code review: verified 53 end-to-end isolated behavioral and security tests covering all script categories, toolbox CLI subcommands, and graceful handling of unbooted systemd environments.

@ashishsinghbora
ashishsinghbora merged commit d211f8e into main Sep 24, 2026
1 check passed
@ashishsinghbora
ashishsinghbora deleted the test/functional-test-suite branch September 24, 2026 18:14
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant