def assert_obtains_file_contents(self, func, file_path, is_text_file):
        self.conn.get_file.return_value = io.BytesIO(b'data')

        output = func()

        self.assertEqual(output, 'data' if is_text_file else b'data')
        self.conn.get_file.assert_called_once_with(file_path)
Asserts that ``func()`` obtains the contents of the given file.
dataset/ETHPy150Open s3rvac/retdec-python/tests/resource_tests.py/WithMockedIO.assert_obtains_file_contents