Skip to content

Commit

Permalink
fix chksum test
Browse files Browse the repository at this point in the history
  • Loading branch information
sellth committed Nov 7, 2023
1 parent 6b72d9d commit 2636c8c
Showing 1 changed file with 8 additions and 2 deletions.
10 changes: 8 additions & 2 deletions tests/test_irods_common.py
Original file line number Diff line number Diff line change
Expand Up @@ -97,8 +97,14 @@ def test_irods_transfer_put(fs, itransfer, jobs):


def test_irods_transfer_chksum(itransfer):
with patch.object(itransfer.session.data_objects, "get") as mock:
with patch.object(itransfer.session.data_objects, "get") as mockget:
mock_data_object = MagicMock()
mockget.return_value = mock_data_object
mock_data_object.checksum = None
mock_data_object.chksum = MagicMock()

itransfer.chksum()

assert mock_data_object.chksum.call_count == len(itransfer.destinations)
for path in itransfer.destinations:
mock.assert_any_call(path)
mockget.assert_any_call(path)

0 comments on commit 2636c8c

Please sign in to comment.