Skip to content

Commit

Permalink
fix test
Browse files Browse the repository at this point in the history
  • Loading branch information
tusharsadhwani committed Oct 31, 2024
1 parent e257573 commit 2e0412d
Showing 1 changed file with 15 additions and 5 deletions.
20 changes: 15 additions & 5 deletions tests/pytest_beartype_test.py
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
from unittest import mock
import pytest

import pytest
import pytest_beartype


Expand All @@ -12,8 +12,18 @@ def test_pytest_addoption() -> None:
with mock.patch.object(pytest.OptionGroup, "addoption") as mock_addoption:
pytest_beartype.pytest_addoption(pytest.Parser())

mock_addoption.assert_called_once_with(
"--beartype-packages",
action="store",
help=mock.ANY,
assert mock_addoption.call_count == 2
mock_addoption.assert_has_calls(
[
mock.call(
"--beartype-packages",
action="store",
help=mock.ANY,
),
mock.call(
"--beartype-skip-packages",
action="store",
help=mock.ANY,
),
]
)

0 comments on commit 2e0412d

Please sign in to comment.