Skip to content

chore: add critical orchestration test coverage#217

Merged
GangGreenTemperTatum merged 2 commits intomainfrom
test/critical-coverage
Mar 30, 2026
Merged

chore: add critical orchestration test coverage#217
GangGreenTemperTatum merged 2 commits intomainfrom
test/critical-coverage

Conversation

@GangGreenTemperTatum
Copy link
Copy Markdown
Collaborator

@GangGreenTemperTatum GangGreenTemperTatum commented Mar 30, 2026

Adds targeted test coverage for the highest-risk untested runtime paths.

What changed

  • Added robust unit tests for Loader.run() orchestration, including argument/volume mapping, artifact handling, profile parsing, stdout merging, timeout behavior, and container error handling.
  • Added Tracer.run_trace() coverage for lifecycle orchestration, tracer error propagation, and containerId event filtering.
  • Added CLI coverage for missing policy validation, non-Linux GPU auto-disable behavior, and verbose exception re-raise behavior.

Why
The existing suite was strong on helpers and formatting, but weak on the Docker/Tracee execution paths most likely to fail in production while tests still stayed green.

Verification

  • pytest dyana -q

Generated Summary:

  • Added tests for the CLI trace command to enhance error handling:

    • Verifies that the command rejects a missing policy file with an appropriate error message.
    • Confirms that GPU is disabled on non-Linux systems during a trace operation.
    • Assures that verbose mode correctly raises exceptions.
  • Introduced a new test class to cover loader run executions:

    • Added functionality to parse profile and merge extra stdout during loader runs.
    • Implemented a test for the run method timing out and correctly killing the container.
    • Verified that the run method handles container execution errors appropriately.
  • Expanded testing coverage for the Tracer class:

    • Added a test to filter tracer events and merge errors from both the tracer and loader.
  • Overall, these changes improve test coverage and robustness in error handling for the CLI and loader functionalities.

This summary was generated with ❤️ by rigging

@GangGreenTemperTatum GangGreenTemperTatum changed the title Add critical orchestration test coverage chore: add critical orchestration test coverage Mar 30, 2026
@GangGreenTemperTatum GangGreenTemperTatum merged commit 181bc31 into main Mar 30, 2026
5 checks passed
@GangGreenTemperTatum GangGreenTemperTatum deleted the test/critical-coverage branch March 30, 2026 20:08
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