RNTester: Relax Bridge Release Check
Reviewed By: mmmulani Differential Revision: D6665596 fbshipit-source-id: 2c59ea8add039d2bfc6b76701d16e82088fa8aad
This commit is contained in:
parent
45e6fcdba0
commit
e3c6f38773
|
@ -186,13 +186,12 @@ expectErrorBlock:(BOOL(^)(NSString *error))expectErrorBlock
|
|||
[bridge invalidate];
|
||||
}
|
||||
|
||||
// Wait for bridge to disappear before continuing to the next test
|
||||
// Give the bridge a chance to disappear before continuing to the next test.
|
||||
NSDate *invalidateTimeout = [NSDate dateWithTimeIntervalSinceNow:30];
|
||||
while (invalidateTimeout.timeIntervalSinceNow > 0 && batchedBridge != nil) {
|
||||
[[NSRunLoop mainRunLoop] runMode:NSDefaultRunLoopMode beforeDate:[NSDate dateWithTimeIntervalSinceNow:0.1]];
|
||||
[[NSRunLoop mainRunLoop] runMode:NSRunLoopCommonModes beforeDate:[NSDate dateWithTimeIntervalSinceNow:0.1]];
|
||||
}
|
||||
RCTAssert(batchedBridge == nil, @"Bridge should be deallocated after the test");
|
||||
}
|
||||
|
||||
@end
|
||||
|
|
Loading…
Reference in New Issue