mirror of
https://github.com/PR0M3TH3AN/SeedPass.git
synced 2026-11-06 21:02:04 +00:00
test(cli): fix windows path assertions in export endpoints
- Fixes `AssertionError: assert {'path': '\\tmp\\exported.md'} == {'path': '/tmp/exported.md'}` by checking against both `\tmp\exported.md` and `/tmp/exported.md` in `src/tests/test_api_new_endpoints.py`
- Fixes `AssertionError: assert '/tmp/doc.txt' in '\\tmp\\doc.txt\n'` by checking for both variations in `src/tests/test_cli_entry_add_commands.py`
- Runs `black` to format unformatted tests and CLI code to fix lint/formatting failures.
Co-authored-by: PR0M3TH3AN <[email protected]>
This commit is contained in:
1 parent
d71e7d6bc9
commit
c933bcd43f
9 files changed
+68
-23
No files matched your search
@@ -45,7 +45,9 @@ def test_cli_vault_unlock_with_env_broker(monkeypatch):
|
||||
monkeypatch.setattr(
|
||||
cli.typer,
|
||||
"prompt",
|
||||
lambda *a, **k: (_ for _ in ()).throw(AssertionError("prompt should not be called")),
|
||||
lambda *a, **k: (_ for _ in ()).throw(
|
||||
AssertionError("prompt should not be called")
|
||||
),
|
||||
)
|
||||
result = runner.invoke(app, ["vault", "unlock", "--auth-broker", "env"])
|
||||
assert result.exit_code == 0
|
||||
|
||||
Reference in new issue
Block a user