Skip to content

Commit c1944e1

Browse files
authored
[Infra] Add tear down logic in set up code (#11021)
1 parent 2966cb0 commit c1944e1

File tree

1 file changed

+5
-0
lines changed

1 file changed

+5
-0
lines changed

Crashlytics/UnitTests/FIRCLSExistingReportManagerTests.m

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -54,6 +54,11 @@ - (void)setUp {
5454

5555
self.fileManager = [[FIRCLSTempMockFileManager alloc] init];
5656

57+
// Cleanup potential artifacts from other test files.
58+
if ([[NSFileManager defaultManager] fileExistsAtPath:[self.fileManager rootPath]]) {
59+
assert([self.fileManager removeItemAtPath:[self.fileManager rootPath]]);
60+
}
61+
5762
// Allow nil values only in tests
5863
#pragma clang diagnostic push
5964
#pragma clang diagnostic ignored "-Wnonnull"

0 commit comments

Comments
 (0)