mirror of
https://github.com/scito/extract_otp_secret_keys.git
synced 2026-01-03 20:09:30 +01:00
allow to choose qr reader for images
This commit is contained in:
parent
2dea161cdc
commit
1f04dd71e2
12 changed files with 112 additions and 29 deletions
|
|
@ -582,6 +582,18 @@ def test_img_qr_reader_from_file_happy_path(capsys: pytest.CaptureFixture[str])
|
|||
assert captured.err == ''
|
||||
|
||||
|
||||
@pytest.mark.qreader
|
||||
def test_img_qr_reader_by_parameter(capsys: pytest.CaptureFixture[str], qr_mode: str) -> None:
|
||||
# Act
|
||||
extract_otp_secrets.main(['--qr', qr_mode, 'tests/data/test_googleauth_export.png'])
|
||||
|
||||
# Assert
|
||||
captured = capsys.readouterr()
|
||||
|
||||
assert captured.out == EXPECTED_STDOUT_FROM_EXAMPLE_EXPORT_PNG
|
||||
assert captured.err == ''
|
||||
|
||||
|
||||
@pytest.mark.qreader
|
||||
def test_extract_multiple_files_and_mixed(capsys: pytest.CaptureFixture[str]) -> None:
|
||||
# Act
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue