aboutsummaryrefslogtreecommitdiffhomepage
path: root/Firestore/Example/Tests/Util/FSTIntegrationTestCase.mm
diff options
context:
space:
mode:
authorGravatar Gil <mcg@google.com>2018-04-14 17:19:06 -0700
committerGravatar GitHub <noreply@github.com>2018-04-14 17:19:06 -0700
commit33b12f6c70729d56c6e6350d435559cec1c44c61 (patch)
tree60d916bb7509f82e8950b887b45f9dd0bf80251a /Firestore/Example/Tests/Util/FSTIntegrationTestCase.mm
parentfd84cd60aaf52cbe405ff8248665029827d56e97 (diff)
Replace `DocumentListenOptions` with a simple boolean. (#1099)
* Replace `DocumentListenOptions` with a simple boolean. Instead of calling `addSnapshotListener(options: DocumentListenOptions.includeMetadataChanges(true))` call `addSnapshotListener(includeMetadataChanges:true)` * Style
Diffstat (limited to 'Firestore/Example/Tests/Util/FSTIntegrationTestCase.mm')
-rw-r--r--Firestore/Example/Tests/Util/FSTIntegrationTestCase.mm17
1 files changed, 9 insertions, 8 deletions
diff --git a/Firestore/Example/Tests/Util/FSTIntegrationTestCase.mm b/Firestore/Example/Tests/Util/FSTIntegrationTestCase.mm
index 79163da..2b1f9d0 100644
--- a/Firestore/Example/Tests/Util/FSTIntegrationTestCase.mm
+++ b/Firestore/Example/Tests/Util/FSTIntegrationTestCase.mm
@@ -245,14 +245,15 @@ NS_ASSUME_NONNULL_BEGIN
XCTestExpectation *expectation = [self expectationWithDescription:@"listener"];
id<FIRListenerRegistration> listener = [ref
- addSnapshotListenerWithOptions:[[FIRDocumentListenOptions options] includeMetadataChanges:YES]
- listener:^(FIRDocumentSnapshot *snapshot, NSError *error) {
- XCTAssertNil(error);
- if (!requireOnline || !snapshot.metadata.fromCache) {
- result = snapshot;
- [expectation fulfill];
- }
- }];
+ addSnapshotListenerWithIncludeMetadataChanges:YES
+ listener:^(FIRDocumentSnapshot *snapshot,
+ NSError *error) {
+ XCTAssertNil(error);
+ if (!requireOnline || !snapshot.metadata.fromCache) {
+ result = snapshot;
+ [expectation fulfill];
+ }
+ }];
[self awaitExpectations];
[listener remove];