From 0d120ed3d387314c675f93225215b2d78db86943 Mon Sep 17 00:00:00 2001 From: Chris Withers Date: Tue, 1 Nov 2022 20:15:18 +0100 Subject: [PATCH] Round out test coverage for Mock Call comparison. --- testfixtures/tests/test_compare.py | 14 ++++++++++++++ 1 file changed, 14 insertions(+) diff --git a/testfixtures/tests/test_compare.py b/testfixtures/tests/test_compare.py index 3b16e55..2be2629 100644 --- a/testfixtures/tests/test_compare.py +++ b/testfixtures/tests/test_compare.py @@ -1559,6 +1559,20 @@ def test_mock_call_same_strict(self): m.foo(1, 2, x=3) compare(m.mock_calls, m.mock_calls, strict=True) + def test_mock_call_equal(self): + m1 = Mock() + m1.foo(1, 2, x=3) + m2 = Mock() + m2.foo(1, 2, x=3) + compare(m1.mock_calls, m2.mock_calls) + + def test_mock_call_equal_strict(self): + m1 = Mock() + m1.foo(1, 2, x=3) + m2 = Mock() + m2.foo(1, 2, x=3) + compare(m1.mock_calls, m2.mock_calls, strict=True) + def test_calls_different(self): m1 = Mock() m2 = Mock()