Orchestrata Ultimate › Tests › Reference › scripts › test_gate_cli
Tests reference — tests/scripts/test_gate_cli.py
Module of tests/scripts, split out because the directory page would be too large.
Prose pending.
tests/scripts/test_gate_cli.py
source · 17 tests · 492 lines
Tests for scripts/gate.py — the Prolog gate layer's CLI seam (P1).
| Kind | Name | Line | Description |
|---|---|---|---|
| class | TestFactsSubcommand |
94 | |
| method | TestFactsSubcommand.test_stats_prints_the_table_and_exits_zero |
95 | |
| method | TestFactsSubcommand.test_out_writes_a_fact_base |
116 | |
| method | TestFactsSubcommand.test_no_flags_still_reports_rather_than_staying_silent |
140 | A command that does its work and prints nothing reads as a no-op. |
| method | TestFactsSubcommand.test_a_missing_snapshot_exits_nonzero_with_the_remedy |
159 | REQ-GATE-003: never a green verdict over a fact base that is absent. |
| class | TestRunSubcommand |
187 | The three exit codes, end to end through the CLI. |
| method | TestRunSubcommand.test_a_clean_project_passes_and_exits_zero |
195 | |
| method | TestRunSubcommand.test_a_violation_exits_one_and_reports_on_stderr |
213 | A failing verdict goes to stderr so a pipeline that only captures |
| method | TestRunSubcommand.test_a_missing_snapshot_exits_two |
235 | |
| class | TestUncoveredSubcommand |
251 | REQ-GATE-011: gate uncovered — a report, not a gate. It always |
| method | TestUncoveredSubcommand.test_names_a_real_unmechanised_policy |
257 | The live acceptance case, reproduced through the CLI: this |
| method | TestUncoveredSubcommand.test_a_native_policy_is_not_reported |
287 | The six native rules (no_relative_import, banned_import, ...) |
| method | TestUncoveredSubcommand.test_a_missing_snapshot_exits_nonzero_with_the_remedy |
317 | REQ-GATE-003's discipline applies here too: a query over a fact |
| class | TestExplainAndWhyNotSubcommandsPrintFormatting |
341 | The engine-level proof-tree / why-not logic (P4) is exercised |
| method | TestExplainAndWhyNotSubcommandsPrintFormatting.test_explain_prints_a_proof_tree_for_a_real_violation |
347 | |
| method | TestExplainAndWhyNotSubcommandsPrintFormatting.test_explain_refuses_a_location_that_does_not_violate |
370 | |
| method | TestExplainAndWhyNotSubcommandsPrintFormatting.test_why_not_prints_the_failing_subgoal |
393 | |
| method | TestExplainAndWhyNotSubcommandsPrintFormatting.test_why_not_refuses_when_no_clause_unifies |
416 | |
| class | TestSubcommandsRefuseRatherThanReturnEmpty |
439 | A command that returns a verdict no rule produced is worse than one that |
| method | TestSubcommandsRefuseRatherThanReturnEmpty.test_a_command_without_its_target_is_rejected |
451 | |
| method | TestSubcommandsRefuseRatherThanReturnEmpty.test_every_declared_subcommand_is_dispatched |
470 | A subcommand added to the parser and forgotten in main's |
| method | TestSubcommandsRefuseRatherThanReturnEmpty.test_no_subcommand_is_rejected |
486 |