Commands that need a DB fail cleanly when --db is not set.
(self)
| 2171 | """CLI gives clean errors for missing/nonexistent --db.""" |
| 2172 | |
| 2173 | def test_no_db_set(self): |
| 2174 | """Commands that need a DB fail cleanly when --db is not set.""" |
| 2175 | |
| 2176 | runner = CliRunner() |
| 2177 | result = runner.invoke(cli, ["show", "stats"]) |
| 2178 | |
| 2179 | self.assertNotEqual(result.exit_code, 0) |
| 2180 | self.assertIn("No database path", result.output) |
| 2181 | |
| 2182 | def test_nonexistent_db(self): |
| 2183 | """Read-only commands fail cleanly when DB file doesn't exist.""" |
nothing calls this directly
no outgoing calls
no test coverage detected