Exemplo n.º 1
0
 def test_get_file_return_none(self, size_and_filename_data):
     (size, filename) = size_and_filename_data
     file_storage = FileStorage(size)
     assert file_storage.get_file(filename) is None
Exemplo n.º 2
0
 def test_get_file_return_file(self, size_filename_content_data):
     (size, filename, content) = size_filename_content_data
     file_storage = FileStorage(size)
     file = File(filename, content)
     file_storage.write(file)
     assert file_storage.get_file(file.get_filename()) == file