Skip to content

Commit 40b41f2

Browse files
authored
Merge branch 'master' into dconeybe/ImproveMissingIndexTestName
2 parents 1e145dd + 2f546b2 commit 40b41f2

File tree

2 files changed

+5
-4
lines changed

2 files changed

+5
-4
lines changed

firebase-firestore/src/androidTest/java/com/google/firebase/firestore/AggregationTest.java

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -903,14 +903,15 @@ public void testAggregateErrorMessageShouldContainConsoleLinkIfMissingIndex() {
903903
Throwable throwable = assertThrows(Throwable.class, () -> waitFor(task));
904904

905905
Throwable cause = throwable.getCause();
906+
Truth.assertThat(cause).hasMessageThat().ignoringCase().contains("index");
907+
// TODO(b/316359394) Remove this check for the default databases once cl/582465034 is rolled
908+
// out to production.
906909
if (collection
907910
.firestore
908911
.getDatabaseId()
909912
.getDatabaseId()
910913
.equals(DatabaseId.DEFAULT_DATABASE_ID)) {
911914
Truth.assertThat(cause).hasMessageThat().contains("https://console.firebase.google.com");
912-
} else {
913-
Truth.assertThat(cause).hasMessageThat().contains("Missing index configuration");
914915
}
915916
}
916917

firebase-firestore/src/androidTest/java/com/google/firebase/firestore/CountTest.java

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -277,14 +277,14 @@ public void testCountErrorMessageShouldContainConsoleLinkIfMissingIndex() {
277277

278278
Throwable cause = throwable.getCause();
279279
assertThat(cause).hasMessageThat().ignoringCase().contains("index");
280+
// TODO(b/316359394) Remove this check for the default databases once cl/582465034 is rolled
281+
// out to production.
280282
if (collection
281283
.firestore
282284
.getDatabaseId()
283285
.getDatabaseId()
284286
.equals(DatabaseId.DEFAULT_DATABASE_ID)) {
285287
assertThat(cause).hasMessageThat().contains("https://console.firebase.google.com");
286-
} else {
287-
assertThat(cause).hasMessageThat().contains("Missing index configuration");
288288
}
289289
}
290290
}

0 commit comments

Comments
 (0)