File tree Expand file tree Collapse file tree 1 file changed +0
-13
lines changed Expand file tree Collapse file tree 1 file changed +0
-13
lines changed Original file line number Diff line number Diff line change 1
- import unittest .mock
2
1
from unittest import mock
3
2
4
3
from sasctl .core import PageIterator , RestObj
@@ -10,19 +9,7 @@ def test_no_paging_required():
10
9
items = [{"name" : "a" }, {"name" : "b" }, {"name" : "c" }]
11
10
obj = RestObj (items = items , count = len (items ))
12
11
13
- import sasctl
14
- assert not isinstance (sasctl .core .request , unittest .mock .Mock )
15
-
16
12
with mock .patch ("sasctl.core.Session.request" ) as req :
17
- # with mock.patch("sasctl.core.request") as req:
18
- req .reset_mock (side_effect = True )
19
- try :
20
- req .assert_not_called ()
21
- except AssertionError :
22
- raise AssertionError (
23
- f"Previous calls: method_calls={ req .mock_calls } call_args={ req .call_args_list } "
24
- )
25
-
26
13
pager = PageIterator (obj )
27
14
28
15
# Returned page of items should preserve item order
You can’t perform that action at this time.
0 commit comments