diff options
Diffstat (limited to 'Example/Database/Tests/Unit/FLevelDBStorageEngineTests.m')
-rw-r--r-- | Example/Database/Tests/Unit/FLevelDBStorageEngineTests.m | 14 |
1 files changed, 14 insertions, 0 deletions
diff --git a/Example/Database/Tests/Unit/FLevelDBStorageEngineTests.m b/Example/Database/Tests/Unit/FLevelDBStorageEngineTests.m index 560104a..99665a0 100644 --- a/Example/Database/Tests/Unit/FLevelDBStorageEngineTests.m +++ b/Example/Database/Tests/Unit/FLevelDBStorageEngineTests.m @@ -426,6 +426,13 @@ // Well this is awkward, but NSJSONSerialization fails to deserialize JSON with tiny/huge doubles // It is kind of bad we raise "invalid" data, but at least we don't crash *trollface* - (void)testExtremeDoublesAsServerCache { +#ifdef TARGET_OS_IOS + if ([[NSProcessInfo processInfo] operatingSystemVersion].majorVersion == 11) { + // NSJSONSerialization on iOS 11 correctly serializes small and large doubles. + return; + } +#endif + FLevelDBStorageEngine *engine = [self cleanStorageEngine]; [engine updateServerCache:NODE((@{@"works": @"value", @"fails": @(2.225073858507201e-308)})) atPath:PATH(@"foo") merge:NO]; @@ -435,6 +442,13 @@ } - (void)testExtremeDoublesAsTrackedQuery { +#ifdef TARGET_OS_IOS + if ([[NSProcessInfo processInfo] operatingSystemVersion].majorVersion == 11) { + // NSJSONSerialization on iOS 11 correctly serializes small and large doubles. + return; + } +#endif + FLevelDBStorageEngine *engine = [self cleanStorageEngine]; id<FNode> tinyDouble = NODE(@(2.225073858507201e-308)); |