Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Run tests from ReactNative #62

Merged
merged 34 commits into from
Oct 19, 2015
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
34 commits
Select commit Hold shift + click to select a range
55a07c9
react test app
alazier Oct 2, 2015
08fada7
fix so that RealmJS tests work again
alazier Oct 2, 2015
d9618a0
remove const, link test app with libRealmReact
alazier Oct 2, 2015
68603c2
fix exports
alazier Oct 2, 2015
2207693
Fix "const" search and replace
appden Oct 6, 2015
db80c3a
Refactor tests to run again inside Xcode
appden Oct 6, 2015
c1fa635
Update ReactTests for iOS 8.0 deployment target
appden Oct 8, 2015
3f37103
Update ReactTests to re-install local NPM modules
appden Oct 8, 2015
8835272
Make all tests explicitly require realm module
appden Oct 8, 2015
dc84ac6
Merge branch 'sk-react-framework' into sk-test-suite
appden Oct 14, 2015
39b262b
Each test can now have a beforeEach and afterEach
appden Oct 14, 2015
2384f2c
catch errors thrown from tests and display error information
alazier Oct 14, 2015
d0787e3
remove android project
alazier Oct 14, 2015
c8c1910
Expose global cleanupTestRealms function
appden Oct 14, 2015
e470c5d
run tests from subclass
alazier Oct 14, 2015
7b5be78
close to working test harness
alazier Oct 15, 2015
94521b7
Properly serialize args to create Realm through RPC
appden Oct 15, 2015
18f97b6
Always set Access-Control-Allow-Origin on response
appden Oct 15, 2015
7a79ac8
Make Xcode tests run in React environment
appden Oct 15, 2015
7f5902b
Remove dependency on JavaScriptCore for RealmReactTests
appden Oct 15, 2015
5d59431
Fix crash when a test fails inside RealmReactTests
appden Oct 15, 2015
eb598a2
fix for in chrome
alazier Oct 16, 2015
45a3c89
remove hardcoded test paths
alazier Oct 16, 2015
5ccc03e
rename some methods for clarity - try to cleanup js objects
alazier Oct 16, 2015
69bf42c
Actually stop and dealloc RPC server
appden Oct 16, 2015
5edb205
clean up prototype and defaults state
alazier Oct 16, 2015
7ae6fe4
make sure we have destructors for all objects
alazier Oct 16, 2015
430b2a2
Merge branch 'sk-test-suite' of https://github.com/realm/realm-js int…
alazier Oct 16, 2015
7074d66
always use release version of core
alazier Oct 19, 2015
832e0c5
clean up ctx initiliazation/remove code duplication
alazier Oct 19, 2015
69ea139
disable schema/defaults cleanup until we can ensure we are using the …
alazier Oct 19, 2015
fae2768
newline
alazier Oct 19, 2015
f02fb05
add search paths for test path
alazier Oct 19, 2015
cfd618d
flag to create jscontext
alazier Oct 19, 2015
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 4 additions & 0 deletions ReactNative/RealmReact.h
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,10 @@
////////////////////////////////////////////////////////////////////////////

@import Foundation;
@import JavaScriptCore;

extern JSGlobalContextRef RealmReactGetJSGlobalContextForExecutor(id executor, bool create);

@interface RealmReact : NSObject

@end
75 changes: 45 additions & 30 deletions ReactNative/RealmReact.m
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,6 @@

@import GCDWebServers;
@import RealmJS;
@import JavaScriptCore;
@import ObjectiveC;
@import Darwin;

Expand All @@ -30,6 +29,28 @@ - (instancetype)initWithJSContext:(JSGlobalContextRef)context;
- (JSGlobalContextRef)ctx;
@end

JSGlobalContextRef RealmReactGetJSGlobalContextForExecutor(id executor, bool create) {
Ivar contextIvar = class_getInstanceVariable([executor class], "_context");
if (!contextIvar) {
return NULL;
}

id rctJSContext = contextIvar ? object_getIvar(executor, contextIvar) : nil;
if (!rctJSContext && create) {
Class RCTJavaScriptContext = NSClassFromString(@"RCTJavaScriptContext");
if (RCTJavaScriptContext) {
JSGlobalContextRef ctx = JSGlobalContextCreate(NULL);
rctJSContext = [[RCTJavaScriptContext alloc] initWithJSContext:ctx];
object_setIvar(executor, contextIvar, rctJSContext);
}
else {
NSLog(@"Failed to load RCTJavaScriptContext class");
}
}

return [rctJSContext ctx];
}

@interface RealmReact () <RCTBridgeModule>
@end

Expand All @@ -55,12 +76,17 @@ + (NSString *)moduleName {
- (void)setBridge:(RCTBridge *)bridge {
_bridge = bridge;

Ivar executorIvar = class_getInstanceVariable([bridge class], "_javaScriptExecutor");
id contextExecutor = object_getIvar(bridge, executorIvar);
Ivar contextIvar = class_getInstanceVariable([contextExecutor class], "_context");
static GCDWebServer *s_webServer;
if (s_webServer) {
[s_webServer stop];
[s_webServer removeAllHandlers];
s_webServer = nil;
}

// The executor could be a RCTWebSocketExecutor, in which case it won't have a JS context.
if (!contextIvar) {
Ivar executorIvar = class_getInstanceVariable([bridge class], "_javaScriptExecutor");
id executor = object_getIvar(bridge, executorIvar);
if ([executor isMemberOfClass:NSClassFromString(@"RCTWebSocketExecutor")]) {
[GCDWebServer setLogLevel:3];
GCDWebServer *webServer = [[GCDWebServer alloc] init];
RJSRPCServer *rpcServer = [[RJSRPCServer alloc] init];
Expand All @@ -72,39 +98,28 @@ - (void)setBridge:(RCTBridge *)bridge {
NSError *error;
NSData *data = [(GCDWebServerDataRequest *)request data];
NSDictionary *json = [NSJSONSerialization JSONObjectWithData:data options:0 error:&error];
if (error) {
NSLog(@"%@", error);
return [GCDWebServerErrorResponse responseWithClientError:kGCDWebServerHTTPStatusCode_UnprocessableEntity underlyingError:error message:@"Invalid RPC request"];
GCDWebServerResponse *response;

if (error || ![json isKindOfClass:[NSDictionary class]]) {
NSLog(@"Invalid RPC request - %@", error ?: json);
response = [GCDWebServerErrorResponse responseWithClientError:kGCDWebServerHTTPStatusCode_UnprocessableEntity underlyingError:error message:@"Invalid RPC request"];
}
else {
response = [GCDWebServerDataResponse responseWithJSONObject:[rpcServer performRequest:request.path args:json]];
}

GCDWebServerDataResponse *response = [GCDWebServerDataResponse responseWithJSONObject:[rpcServer performRequest:request.path args:json]];

[response setValue:@"http://localhost:8081" forAdditionalHeader:@"Access-Control-Allow-Origin"];
return response;
}];
}];

[webServer startWithPort:8082 bonjourName:nil];

s_webServer = webServer;
return;
}

[contextExecutor executeBlockOnJavaScriptQueue:^{
id rctJSContext = object_getIvar(contextExecutor, contextIvar);
JSGlobalContextRef ctx;

if (rctJSContext) {
ctx = [rctJSContext ctx];
}
else {
Class RCTJavaScriptContext = NSClassFromString(@"RCTJavaScriptContext");

if (RCTJavaScriptContext) {
ctx = JSGlobalContextCreate(NULL);
object_setIvar(contextExecutor, contextIvar, [[RCTJavaScriptContext alloc] initWithJSContext:ctx]);
}
else {
NSLog(@"Failed to load RCTJavaScriptContext class");
}
}

[executor executeBlockOnJavaScriptQueue:^{
JSGlobalContextRef ctx = RealmReactGetJSGlobalContextForExecutor(executor, true);
[RealmJS initializeContext:ctx];
}];
}
Expand Down
61 changes: 41 additions & 20 deletions RealmJS.xcodeproj/project.pbxproj
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@
/* Begin PBXBuildFile section */
02258FB31BC6E2D00075F13A /* RealmRPC.h in Headers */ = {isa = PBXBuildFile; fileRef = 02258FB11BC6E2D00075F13A /* RealmRPC.h */; settings = {ATTRIBUTES = (Public, ); }; };
02258FB41BC6E2D00075F13A /* RealmRPC.mm in Sources */ = {isa = PBXBuildFile; fileRef = 02258FB21BC6E2D00075F13A /* RealmRPC.mm */; };
02409DC21BCF11D6005F3B3E /* RealmJSCoreTests.m in Sources */ = {isa = PBXBuildFile; fileRef = 02409DC11BCF11D6005F3B3E /* RealmJSCoreTests.m */; settings = {ASSET_TAGS = (); }; };
02601F031BA0F0C4007C91FF /* external_commit_helper.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 02601F011BA0F0C4007C91FF /* external_commit_helper.cpp */; };
02601F041BA0F0C4007C91FF /* external_commit_helper.hpp in Headers */ = {isa = PBXBuildFile; fileRef = 02601F021BA0F0C4007C91FF /* external_commit_helper.hpp */; };
02601F081BA0F0CD007C91FF /* index_set.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 02601F051BA0F0CD007C91FF /* index_set.cpp */; };
Expand Down Expand Up @@ -46,8 +47,8 @@
0270BC821B7D020100010E03 /* RealmJSTests.mm in Sources */ = {isa = PBXBuildFile; fileRef = 0270BC7B1B7D020100010E03 /* RealmJSTests.mm */; };
0270BC831B7D020100010E03 /* RealmTests.js in Resources */ = {isa = PBXBuildFile; fileRef = 0270BC7C1B7D020100010E03 /* RealmTests.js */; };
0270BC841B7D020100010E03 /* ResultsTests.js in Resources */ = {isa = PBXBuildFile; fileRef = 0270BC7D1B7D020100010E03 /* ResultsTests.js */; };
0270BC851B7D020100010E03 /* TestCase.js in Resources */ = {isa = PBXBuildFile; fileRef = 0270BC7E1B7D020100010E03 /* TestCase.js */; };
0270BC861B7D020100010E03 /* TestObjects.js in Resources */ = {isa = PBXBuildFile; fileRef = 0270BC7F1B7D020100010E03 /* TestObjects.js */; };
0270BC851B7D020100010E03 /* asserts.js in Resources */ = {isa = PBXBuildFile; fileRef = 0270BC7E1B7D020100010E03 /* asserts.js */; };
0270BC861B7D020100010E03 /* schemas.js in Resources */ = {isa = PBXBuildFile; fileRef = 0270BC7F1B7D020100010E03 /* schemas.js */; };
0270BC871B7D023200010E03 /* RealmJS.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 02B58CB11AE99CEC009B348C /* RealmJS.framework */; };
0270BCD11B7D067300010E03 /* RealmReact.m in Sources */ = {isa = PBXBuildFile; fileRef = 0270BCD01B7D067300010E03 /* RealmReact.m */; };
02B29A311B7CF86D008A7E6B /* RealmJS.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 02B58CB11AE99CEC009B348C /* RealmJS.framework */; };
Expand All @@ -58,8 +59,12 @@
02D8D1F71B601984006DB49D /* JavaScriptCore.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 02B58CCD1AE99D4D009B348C /* JavaScriptCore.framework */; };
F636F6C81BCDB3570023F35C /* RealmReact.h in Headers */ = {isa = PBXBuildFile; fileRef = 0270BCCF1B7D067300010E03 /* RealmReact.h */; settings = {ATTRIBUTES = (Public, ); }; };
F64426C51BCDB1E200A81210 /* RealmJS.framework in Embed Frameworks */ = {isa = PBXBuildFile; fileRef = 02B58CB11AE99CEC009B348C /* RealmJS.framework */; settings = {ATTRIBUTES = (CodeSignOnCopy, RemoveHeadersOnCopy, ); }; };
F64E1EF11BC3510E00E0E150 /* util.js in Resources */ = {isa = PBXBuildFile; fileRef = F64E1EF01BC3510E00E0E150 /* util.js */; settings = {ASSET_TAGS = (); }; };
F67191381BCE231100AD0939 /* GCDWebServers.framework in Embed Frameworks */ = {isa = PBXBuildFile; fileRef = 02A3C7941BC4317A00B1A7BE /* GCDWebServers.framework */; settings = {ATTRIBUTES = (CodeSignOnCopy, RemoveHeadersOnCopy, ); }; };
F68A278C1BC2722A0063D40A /* RJSModuleLoader.m in Sources */ = {isa = PBXBuildFile; fileRef = F68A278B1BC2722A0063D40A /* RJSModuleLoader.m */; settings = {ASSET_TAGS = (); }; };
F68A278E1BC30F0A0063D40A /* index.js in Resources */ = {isa = PBXBuildFile; fileRef = F68A278D1BC30F0A0063D40A /* index.js */; settings = {ASSET_TAGS = (); }; };
F6B3963D1BCE2430008BDC39 /* GCDWebServers.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 02A3C7941BC4317A00B1A7BE /* GCDWebServers.framework */; };
F6F405F81BCF0C1A00A1E24F /* base-test.js in Resources */ = {isa = PBXBuildFile; fileRef = F6F405F71BCF0C1A00A1E24F /* base-test.js */; settings = {ASSET_TAGS = (); }; };
/* End PBXBuildFile section */

/* Begin PBXContainerItemProxy section */
Expand Down Expand Up @@ -139,6 +144,7 @@
/* Begin PBXFileReference section */
02258FB11BC6E2D00075F13A /* RealmRPC.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = RealmRPC.h; path = src/RealmRPC.h; sourceTree = "<group>"; };
02258FB21BC6E2D00075F13A /* RealmRPC.mm */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.objcpp; name = RealmRPC.mm; path = src/RealmRPC.mm; sourceTree = "<group>"; };
02409DC11BCF11D6005F3B3E /* RealmJSCoreTests.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = RealmJSCoreTests.m; path = src/RealmJSCoreTests.m; sourceTree = SOURCE_ROOT; };
02601F011BA0F0C4007C91FF /* external_commit_helper.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = external_commit_helper.cpp; path = "src/object-store/apple/external_commit_helper.cpp"; sourceTree = "<group>"; };
02601F021BA0F0C4007C91FF /* external_commit_helper.hpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.h; name = external_commit_helper.hpp; path = "src/object-store/apple/external_commit_helper.hpp"; sourceTree = "<group>"; };
02601F051BA0F0CD007C91FF /* index_set.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = index_set.cpp; path = "src/object-store/index_set.cpp"; sourceTree = "<group>"; };
Expand Down Expand Up @@ -179,8 +185,8 @@
0270BC7B1B7D020100010E03 /* RealmJSTests.mm */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.objcpp; name = RealmJSTests.mm; path = tests/RealmJSTests.mm; sourceTree = SOURCE_ROOT; };
0270BC7C1B7D020100010E03 /* RealmTests.js */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.javascript; name = RealmTests.js; path = tests/RealmTests.js; sourceTree = SOURCE_ROOT; };
0270BC7D1B7D020100010E03 /* ResultsTests.js */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.javascript; name = ResultsTests.js; path = tests/ResultsTests.js; sourceTree = SOURCE_ROOT; };
0270BC7E1B7D020100010E03 /* TestCase.js */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.javascript; name = TestCase.js; path = tests/TestCase.js; sourceTree = SOURCE_ROOT; };
0270BC7F1B7D020100010E03 /* TestObjects.js */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.javascript; name = TestObjects.js; path = tests/TestObjects.js; sourceTree = SOURCE_ROOT; };
0270BC7E1B7D020100010E03 /* asserts.js */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.javascript; name = asserts.js; path = tests/asserts.js; sourceTree = SOURCE_ROOT; };
0270BC7F1B7D020100010E03 /* schemas.js */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.javascript; name = schemas.js; path = tests/schemas.js; sourceTree = SOURCE_ROOT; };
0270BCCF1B7D067300010E03 /* RealmReact.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = RealmReact.h; path = ReactNative/RealmReact.h; sourceTree = "<group>"; };
0270BCD01B7D067300010E03 /* RealmReact.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = RealmReact.m; path = ReactNative/RealmReact.m; sourceTree = "<group>"; };
02A3C7841BC4317A00B1A7BE /* GCDWebServer.xcodeproj */ = {isa = PBXFileReference; lastKnownFileType = "wrapper.pb-project"; name = GCDWebServer.xcodeproj; path = vendor/GCDWebServer/GCDWebServer.xcodeproj; sourceTree = "<group>"; };
Expand All @@ -192,6 +198,11 @@
02C0864C1BCDB27000942F9C /* list.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = list.cpp; path = "src/object-store/list.cpp"; sourceTree = "<group>"; };
02C0864D1BCDB27000942F9C /* list.hpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.h; name = list.hpp; path = "src/object-store/list.hpp"; sourceTree = "<group>"; };
02D456D91B7E59A500EE1299 /* ArrayTests.js */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.javascript; name = ArrayTests.js; path = tests/ArrayTests.js; sourceTree = SOURCE_ROOT; };
F64E1EF01BC3510E00E0E150 /* util.js */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.javascript; name = util.js; path = tests/util.js; sourceTree = SOURCE_ROOT; };
F68A278A1BC2722A0063D40A /* RJSModuleLoader.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = RJSModuleLoader.h; path = tests/RJSModuleLoader.h; sourceTree = SOURCE_ROOT; };
F68A278B1BC2722A0063D40A /* RJSModuleLoader.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = RJSModuleLoader.m; path = tests/RJSModuleLoader.m; sourceTree = SOURCE_ROOT; };
F68A278D1BC30F0A0063D40A /* index.js */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.javascript; name = index.js; path = tests/index.js; sourceTree = SOURCE_ROOT; };
F6F405F71BCF0C1A00A1E24F /* base-test.js */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.javascript; name = "base-test.js"; path = "tests/base-test.js"; sourceTree = SOURCE_ROOT; };
/* End PBXFileReference section */

/* Begin PBXFrameworksBuildPhase section */
Expand Down Expand Up @@ -315,15 +326,21 @@
02B58CC01AE99CEC009B348C /* RealmJSTests */ = {
isa = PBXGroup;
children = (
02D456D91B7E59A500EE1299 /* ArrayTests.js */,
0270BC781B7D020100010E03 /* Info.plist */,
F68A278D1BC30F0A0063D40A /* index.js */,
0270BC7E1B7D020100010E03 /* asserts.js */,
F6F405F71BCF0C1A00A1E24F /* base-test.js */,
0270BC7F1B7D020100010E03 /* schemas.js */,
F64E1EF01BC3510E00E0E150 /* util.js */,
02D456D91B7E59A500EE1299 /* ArrayTests.js */,
0270BC791B7D020100010E03 /* ObjectTests.js */,
0270BC7A1B7D020100010E03 /* RealmJSTests.h */,
0270BC7B1B7D020100010E03 /* RealmJSTests.mm */,
0270BC7C1B7D020100010E03 /* RealmTests.js */,
0270BC7D1B7D020100010E03 /* ResultsTests.js */,
0270BC7F1B7D020100010E03 /* TestObjects.js */,
0270BC7E1B7D020100010E03 /* TestCase.js */,
0270BC7A1B7D020100010E03 /* RealmJSTests.h */,
0270BC7B1B7D020100010E03 /* RealmJSTests.mm */,
02409DC11BCF11D6005F3B3E /* RealmJSCoreTests.m */,
F68A278A1BC2722A0063D40A /* RJSModuleLoader.h */,
F68A278B1BC2722A0063D40A /* RJSModuleLoader.m */,
);
path = RealmJSTests;
sourceTree = "<group>";
Expand Down Expand Up @@ -530,10 +547,13 @@
isa = PBXResourcesBuildPhase;
buildActionMask = 2147483647;
files = (
0270BC851B7D020100010E03 /* TestCase.js in Resources */,
F64E1EF11BC3510E00E0E150 /* util.js in Resources */,
0270BC851B7D020100010E03 /* asserts.js in Resources */,
0270BC811B7D020100010E03 /* ObjectTests.js in Resources */,
02D456DA1B7E59A500EE1299 /* ArrayTests.js in Resources */,
0270BC861B7D020100010E03 /* TestObjects.js in Resources */,
0270BC861B7D020100010E03 /* schemas.js in Resources */,
F6F405F81BCF0C1A00A1E24F /* base-test.js in Resources */,
F68A278E1BC30F0A0063D40A /* index.js in Resources */,
0270BC831B7D020100010E03 /* RealmTests.js in Resources */,
0270BC841B7D020100010E03 /* ResultsTests.js in Resources */,
);
Expand Down Expand Up @@ -595,7 +615,9 @@
isa = PBXSourcesBuildPhase;
buildActionMask = 2147483647;
files = (
F68A278C1BC2722A0063D40A /* RJSModuleLoader.m in Sources */,
0270BC821B7D020100010E03 /* RealmJSTests.mm in Sources */,
02409DC21BCF11D6005F3B3E /* RealmJSCoreTests.m in Sources */,
);
runOnlyForDeploymentPostprocessing = 0;
};
Expand Down Expand Up @@ -640,6 +662,7 @@
"$(inherited)",
/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/include,
"$(SRCROOT)/examples/ReactExample/node_modules/react-native/React/",
"$(SRCROOT)/tests/ReactTests/node_modules/react-native/React/",
);
INFOPLIST_FILE = src/Info.plist;
INSTALL_PATH = "$(LOCAL_LIBRARY_DIR)/Frameworks";
Expand Down Expand Up @@ -672,6 +695,7 @@
"$(inherited)",
/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/include,
"$(SRCROOT)/examples/ReactExample/node_modules/react-native/React/",
"$(SRCROOT)/tests/ReactTests/node_modules/react-native/React/",
);
INFOPLIST_FILE = src/Info.plist;
INSTALL_PATH = "$(LOCAL_LIBRARY_DIR)/Frameworks";
Expand Down Expand Up @@ -704,6 +728,7 @@
"$(inherited)",
/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/include,
"$(SRCROOT)/examples/ReactExample/node_modules/react-native/React/",
"$(SRCROOT)/tests/ReactTests/node_modules/react-native/React/",
);
INFOPLIST_FILE = src/Info.plist;
INSTALL_PATH = "$(LOCAL_LIBRARY_DIR)/Frameworks";
Expand Down Expand Up @@ -750,7 +775,6 @@
GCC_OPTIMIZATION_LEVEL = 0;
GCC_PREPROCESSOR_DEFINITIONS = (
REALM_HAVE_CONFIG,
REALM_DEBUG,
__ASSERTMACROS__,
);
GCC_SYMBOLS_PRIVATE_EXTERN = NO;
Expand Down Expand Up @@ -830,7 +854,6 @@
GCC_PREPROCESSOR_DEFINITIONS = (
REALM_HAVE_CONFIG,
"DEBUG=1",
REALM_DEBUG,
__ASSERTMACROS__,
);
HEADER_SEARCH_PATHS = (
Expand All @@ -847,8 +870,8 @@
"-isystem",
core/include,
);
OTHER_LDFLAGS = "-lrealm-ios-dbg";
OTHER_LIBTOOLFLAGS = "-lrealm-ios-dbg";
OTHER_LDFLAGS = "-lrealm-ios";
OTHER_LIBTOOLFLAGS = "";
PRODUCT_BUNDLE_IDENTIFIER = "io.realm.$(PRODUCT_NAME:rfc1034identifier)";
PRODUCT_NAME = "$(TARGET_NAME)";
SKIP_INSTALL = YES;
Expand Down Expand Up @@ -881,7 +904,7 @@
core/include,
);
OTHER_LDFLAGS = "-lrealm-ios";
OTHER_LIBTOOLFLAGS = "-lrealm-ios";
OTHER_LIBTOOLFLAGS = "";
PRODUCT_BUNDLE_IDENTIFIER = "io.realm.$(PRODUCT_NAME:rfc1034identifier)";
PRODUCT_NAME = "$(TARGET_NAME)";
SKIP_INSTALL = YES;
Expand Down Expand Up @@ -964,7 +987,6 @@
GCC_OPTIMIZATION_LEVEL = 0;
GCC_PREPROCESSOR_DEFINITIONS = (
REALM_HAVE_CONFIG,
REALM_DEBUG,
__ASSERTMACROS__,
);
GCC_SYMBOLS_PRIVATE_EXTERN = NO;
Expand Down Expand Up @@ -998,7 +1020,6 @@
GCC_PREPROCESSOR_DEFINITIONS = (
REALM_HAVE_CONFIG,
"DEBUG=1",
REALM_DEBUG,
__ASSERTMACROS__,
);
HEADER_SEARCH_PATHS = (
Expand All @@ -1015,8 +1036,8 @@
"-isystem",
core/include,
);
OTHER_LDFLAGS = "-lrealm-ios-dbg";
OTHER_LIBTOOLFLAGS = "-lrealm-ios-dbg";
OTHER_LDFLAGS = "-lrealm-ios";
OTHER_LIBTOOLFLAGS = "";
PRODUCT_BUNDLE_IDENTIFIER = "io.realm.$(PRODUCT_NAME:rfc1034identifier)";
PRODUCT_NAME = "$(TARGET_NAME)";
SKIP_INSTALL = YES;
Expand Down
Loading