What problem does it solve?
Writing test scenarios for ComplianceAsCode security rules requires deep knowledge of the Automatus framework, Jinja2 templating, OVAL checks, and remediation behavior. This Skill guides the creation of correct pass/fail test scenarios for Linux rules, reducing trial-and-error and broken tests.
Core Features & Use Cases
- Rule Analysis: Reads rule.yml and rendered OVAL/remediation content via MCP tools to determine exactly what to test.
- Scenario Design: Proposes pass and fail scenario pairs covering edge cases like missing config, wrong values, and .d directories.
- Test Authoring: Writes Bash test files using project Jinja2 syntax, shared helpers from tests/shared/, and templated scenarios for reusable rules.
- Verification: Runs scenarios through Automatus with oscap and ansible remediations and interprets results.
- Use Case: Given a rule ID like sshd_disable_root_login, generate a complete set of pass and fail test scenarios, place them in the correct directory, and verify they pass in Automatus.
Quick Start
Create Automatus test scenarios for the rule sshd_disable_root_login and verify them with the test-rule skill.