Skip to content

Commit

Permalink
Remove need for UUID namespaced defaults
Browse files Browse the repository at this point in the history
  • Loading branch information
ncooke3 committed Apr 12, 2024
1 parent c533b8e commit 38510f1
Showing 1 changed file with 4 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -30,18 +30,19 @@ @interface FIRIAMBookKeeperViaUserDefaultsTests : XCTestCase
extern NSString *FIRIAM_ImpressionDictKeyForID;
extern NSString *FIRIAM_ImpressionDictKeyForTimestamp;

static NSString *const kSuiteName = @"FIRIAMBookKeeperViaUserDefaultsTests";

@implementation FIRIAMBookKeeperViaUserDefaultsTests
- (void)setUp {
[super setUp];
NSString *suiteName = [[NSString alloc]
initWithFormat:@"FIRIAMBookKeeperViaUserDefaultsTests-%@", [NSUUID UUID].UUIDString];
self.userDefaultsForTesting = [[GULUserDefaults alloc] initWithSuiteName:suiteName];
self.userDefaultsForTesting = [[GULUserDefaults alloc] initWithSuiteName:kSuiteName];
}

- (void)tearDown {
// Put teardown code here. This method is called after the invocation of each test method in the
// class.
[super tearDown];
[[[NSUserDefaults alloc] initWithSuiteName:kSuiteName] removePersistentDomainForName:kSuiteName];
}

- (void)testRecordImpressionRecords {
Expand Down

0 comments on commit 38510f1

Please sign in to comment.