Error Running Unit Tests

I'm trying to run a unit test target and am unable to. I receive the following error in the test runner output:

The test bundle at /Users/brian/Code/BigBig Bomb/instabomb-ios/src/build/Debug-iphonesimulator/InstaBombTests.octest could not be loaded because a link error occurred.  It is likely that dyld cannot locate a framework framework or library that the the test bundle was linked against, possibly because the framework or library had an incorrect install path at link time.

Tests run fine in XCode 4. I did notice that the error only occurs when including code from my main project target:

- (void) testFail {
    InstaEngine *engine = [[InstaEngine alloc] init];
    STAssertNotNil(engine, @"Engine is nil");
    [engine release];
}



If I just have a basic test things run fine:

- (void) testFail {
    STAssertTrue(false, @"Works");
}


Any ideas?
2 comments
Comment actions Permalink

Looks like the same problem. That thread doesn't appear to have a resolution, though. Are you just requesting that I post the test bundle dependencies and their paths?

D3BE7089136B4760001B83E1 /* Debug */ = {

               isa = XCBuildConfiguration;

               buildSettings = {

                    ALWAYS_SEARCH_USER_PATHS = NO;

                    ARCHS = "$(ARCHS_STANDARD_32_BIT)";

                    BUNDLE_LOADER = "$(BUILT_PRODUCTS_DIR)/InstaBomb.app/InstaBomb";

                    FRAMEWORK_SEARCH_PATHS = (

                         "$(SDKROOT)/Developer/Library/Frameworks",

                         "$(DEVELOPER_LIBRARY_DIR)/Frameworks",

                    );

                    GCC_PRECOMPILE_PREFIX_HEADER = YES;

                    GCC_PREFIX_HEADER = "InstaBombTests/InstaBombTests-Prefix.pch";

                    INFOPLIST_FILE = "InstaBombTests/InstaBombTests-Info.plist";

                    OTHER_LDFLAGS = (

                         "-framework",

                         SenTestingKit,

                    );

                    PRODUCT_NAME = "$(TARGET_NAME)";

                    TEST_AFTER_BUILD = NO;

                    TEST_HOST = "$(BUNDLE_LOADER)";

                    WRAPPER_EXTENSION = octest;

               };

               name = Debug;

          };



0

Please sign in to leave a comment.