Fix test breakage from changes around shared factory objects

This commit is contained in:
Blake Watters
2012-09-29 17:54:09 -04:00
parent 1c6564f823
commit 03439f2464
3 changed files with 27 additions and 1 deletions

View File

@@ -15,6 +15,16 @@
@implementation NSEntityDescription_RKAdditionsTest
- (void)setUp
{
[RKTestFactory setUp];
}
- (void)tearDown
{
[RKTestFactory tearDown];
}
- (void)testRetrievalOfPrimaryKeyFromXcdatamodel
{
RKManagedObjectStore *managedObjectStore = [RKTestFactory managedObjectStore];

View File

@@ -17,6 +17,16 @@
@implementation NSManagedObjectContext_RKAdditionsTest
- (void)setUp
{
[RKTestFactory setUp];
}
- (void)tearDown
{
[RKTestFactory tearDown];
}
- (void)testFetchObjectForEntityWithValueForPrimaryKeyAttribute
{
RKManagedObjectStore *managedObjectStore = [RKTestFactory managedObjectStore];
@@ -51,7 +61,7 @@
assertThatInteger(count, is(equalToInteger(1)));
RKHuman *foundHuman = [managedObjectStore.primaryManagedObjectContext fetchObjectForEntityForName:@"RKHuman" withValueForPrimaryKeyAttribute:[NSNumber numberWithInt:12345]];
assertThat(foundHuman, is(nilValue()));
assertThat(foundHuman, is(notNilValue()));
foundHuman = [context fetchObjectForEntityForName:@"RKHuman" withValueForPrimaryKeyAttribute:[NSNumber numberWithInt:12345]];
assertThat(foundHuman, is(equalTo(human)));