Skip to content

Commit 194e042

Browse files
committed
Add logging to tests
1 parent c11a478 commit 194e042

File tree

1 file changed

+11
-0
lines changed

1 file changed

+11
-0
lines changed

firestore/testapp/Assets/Firebase/Sample/Firestore/UIHandlerAutomated.cs

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4680,6 +4680,17 @@ private void AssertQueryResults(string desc, Query query, List<string> docIds) {
46804680
private void AssertQueryResults(string desc, Query query, List<string> docIds, long count) {
46814681
var snapshot = Await(query.GetSnapshotAsync());
46824682

4683+
if (docIds.Count != count) {
4684+
UnityEngine.Debug.Log("=-=-= WTF!!!");
4685+
}
4686+
4687+
if (snapshot.Count != docIds.Count) {
4688+
UnityEngine.Debug.Log("===== Got a snapshot for " + desc + ". Count: " + snapshot.Count + " expected: " + count);
4689+
for (int i = 0; i < snapshot.Count; i++) {
4690+
UnityEngine.Debug.Log("===== snapshot[" + i + "]: " + snapshot[i].Id);
4691+
}
4692+
}
4693+
46834694
AssertEq(desc + ": Query result count", snapshot.Count, docIds.Count);
46844695
for (int i = 0; i < snapshot.Count; i++) {
46854696
AssertEq(desc + ": Document ID " + i, docIds[i], snapshot[i].Id);

0 commit comments

Comments
 (0)