Google Toolbox For Mac with Core Data on iPhone results in error
- by JaanusSiim
I have set up my project for using Google Toolbox for Mac as described on official wiki. And everything is working as expected.
For core data usage I have created a 'database' class that uses for final application SQLite storage (this is done based on Xcode template code).
For unit tests I have created separate init method for 'database' to use in memory storage (storage url is [NSURL URLWithString:@"memory://store"] and type NSInMemoryStoreType).
Without adding my model file (*.xcdatamodel) to unit tests target, test fail in expected place with message:
executeFetchRequest:error: A fetch request must have an entity.
If I add model file to the test target, then test is executed as expected (core data part looks OK), but after tests execution I get:
RunIPhoneUnitTest.sh: line 123: 9487 Segmentation fault "$TARGET_BUILD_DIR/$EXECUTABLE_PATH" -RegisterForSystemEvents
Command /bin/sh failed with exit code 139
This problem does not looks directly related to core data, but only happens if model file is added to target.
Any pointers on resolving this issue would be appreciated!