Skip to content

Commit 74af096

Browse files
committed
updating integration test to also look at the message portion of the exception.
1 parent 73aff40 commit 74af096

File tree

1 file changed

+10
-0
lines changed

1 file changed

+10
-0
lines changed

packages/cloud_firestore/cloud_firestore/example/integration_test/document_reference_e2e.dart

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -525,6 +525,16 @@ void runDocumentReferenceTests() {
525525
isA<FirebaseException>()
526526
.having((e) => e.code, 'code', 'not-found'),
527527
);
528+
529+
// https://github.com/firebase/flutterfire/pull/12813
530+
// Use platformException.message, which is more detailed, rather than the
531+
// platformException.details['message'] which is the generic:
532+
// 'Some requested document was not found'
533+
expect(
534+
e,
535+
isA<FirebaseException>().having((e) => e.message, 'message',
536+
isNot(contains('Some requested document was not found'))),
537+
);
528538
}
529539
},
530540
);

0 commit comments

Comments
 (0)