def test_isfile_when_file_does_not_exist_returns_false(self) -> None: with self.get_bucket_swap: self.assertFalse( cloud_storage_services.isfile('bucket_1', 'path/to/file.txt'))
def test_isfile_when_file_exists_returns_true(self) -> None: self.bucket_1.blobs['path/to/file.txt'] = MockBlob('path/to/file.txt') with self.get_client_swap: self.assertTrue( cloud_storage_services.isfile('bucket_1', 'path/to/file.txt'))