예제 #1
0
def test_copyto_file_object(copy_client, copyto_sample_query,
                            copyto_expected_result):
    in_memory_target_fileobj = InMemIO()

    copy_client.copyto_file_object(copyto_sample_query,
                                   in_memory_target_fileobj)
    assert in_memory_target_fileobj.getvalue() == copyto_expected_result

    in_memory_target_fileobj.close()
예제 #2
0
def test_copyto_file_object(copy_client, copyto_sample_query,
                            copyto_expected_result):
    in_memory_target_fileobj = InMemIO()

    copy_client.copyto_file_object(copyto_sample_query,
                                   in_memory_target_fileobj)
    assert in_memory_target_fileobj.getvalue() == copyto_expected_result

    in_memory_target_fileobj.close()
예제 #3
0
 def _get_map(self):
     file = BytesIO(cache(self, self.map_path))
     remap = np.load(file)
     file.close()
     return remap