Skip to content

Commit 9bc62af

Browse files
committed
Sync spec tests
1 parent ae246af commit 9bc62af

File tree

3 files changed

+49
-58
lines changed

3 files changed

+49
-58
lines changed

firebase-firestore/src/test/resources/json/bundle_spec_test.json

Lines changed: 4 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -3,8 +3,7 @@
33
"describeName": "Bundles:",
44
"itName": "Bundles query can be loaded and resumed from different tabs",
55
"tags": [
6-
"multi-client",
7-
"no-ios"
6+
"multi-client"
87
],
98
"config": {
109
"numClients": 2,
@@ -226,7 +225,6 @@
226225
"describeName": "Bundles:",
227226
"itName": "Bundles query can be resumed from same query.",
228227
"tags": [
229-
"no-ios"
230228
],
231229
"config": {
232230
"numClients": 1,
@@ -299,8 +297,7 @@
299297
"describeName": "Bundles:",
300298
"itName": "Load and observe from same secondary client",
301299
"tags": [
302-
"multi-client",
303-
"no-ios"
300+
"multi-client"
304301
],
305302
"config": {
306303
"numClients": 2,
@@ -512,8 +509,7 @@
512509
"describeName": "Bundles:",
513510
"itName": "Load from primary client and observe from secondary",
514511
"tags": [
515-
"multi-client",
516-
"no-ios"
512+
"multi-client"
517513
],
518514
"config": {
519515
"numClients": 2,
@@ -761,8 +757,7 @@
761757
"describeName": "Bundles:",
762758
"itName": "Load from secondary clients and observe from primary",
763759
"tags": [
764-
"multi-client",
765-
"no-ios"
760+
"multi-client"
766761
],
767762
"config": {
768763
"numClients": 2,
@@ -921,7 +916,6 @@
921916
"describeName": "Bundles:",
922917
"itName": "Newer deleted docs from bundles should delete cached docs",
923918
"tags": [
924-
"no-ios"
925919
],
926920
"config": {
927921
"numClients": 1,
@@ -1062,7 +1056,6 @@
10621056
"describeName": "Bundles:",
10631057
"itName": "Newer docs from bundles might lead to limbo doc",
10641058
"tags": [
1065-
"no-ios"
10661059
],
10671060
"config": {
10681061
"numClients": 1,
@@ -1284,7 +1277,6 @@
12841277
"describeName": "Bundles:",
12851278
"itName": "Newer docs from bundles should keep not raise snapshot if there are unacknowledged writes",
12861279
"tags": [
1287-
"no-ios"
12881280
],
12891281
"config": {
12901282
"numClients": 1,
@@ -1433,7 +1425,6 @@
14331425
"describeName": "Bundles:",
14341426
"itName": "Newer docs from bundles should overwrite cache",
14351427
"tags": [
1436-
"no-ios"
14371428
],
14381429
"config": {
14391430
"numClients": 1,
@@ -1574,7 +1565,6 @@
15741565
"describeName": "Bundles:",
15751566
"itName": "Newer docs from bundles should raise snapshot only when Watch catches up with acknowledged writes",
15761567
"tags": [
1577-
"no-ios"
15781568
],
15791569
"config": {
15801570
"numClients": 1,
@@ -1768,7 +1758,6 @@
17681758
"describeName": "Bundles:",
17691759
"itName": "Older deleted docs from bundles should do nothing",
17701760
"tags": [
1771-
"no-ios"
17721761
],
17731762
"config": {
17741763
"numClients": 1,

firebase-firestore/src/test/resources/json/garbage_collection_spec_test.json

Lines changed: 41 additions & 41 deletions
Original file line numberDiff line numberDiff line change
@@ -768,9 +768,9 @@
768768
}
769769
]
770770
},
771-
"Contents of query are kept after listen is removed, and GC threshold is reached": {
771+
"Contents of query are kept after listen is removed.": {
772772
"describeName": "Garbage Collection:",
773-
"itName": "Contents of query are kept after listen is removed, and GC threshold is reached",
773+
"itName": "Contents of query are kept after listen is removed.",
774774
"tags": [
775775
],
776776
"config": {
@@ -891,9 +891,6 @@
891891
}
892892
}
893893
},
894-
{
895-
"triggerLruGC": 1
896-
},
897894
{
898895
"userListen": {
899896
"query": {
@@ -903,11 +900,39 @@
903900
],
904901
"path": "collection"
905902
},
906-
"targetId": 4
903+
"targetId": 2
907904
},
905+
"expectedSnapshotEvents": [
906+
{
907+
"added": [
908+
{
909+
"createTime": 0,
910+
"key": "collection/a",
911+
"options": {
912+
"hasCommittedMutations": false,
913+
"hasLocalMutations": false
914+
},
915+
"value": {
916+
"key": "a"
917+
},
918+
"version": 1000
919+
}
920+
],
921+
"errorCode": 0,
922+
"fromCache": true,
923+
"hasPendingWrites": false,
924+
"query": {
925+
"filters": [
926+
],
927+
"orderBys": [
928+
],
929+
"path": "collection"
930+
}
931+
}
932+
],
908933
"expectedState": {
909934
"activeTargets": {
910-
"4": {
935+
"2": {
911936
"queries": [
912937
{
913938
"filters": [
@@ -917,16 +942,16 @@
917942
"path": "collection"
918943
}
919944
],
920-
"resumeToken": ""
945+
"resumeToken": "resume-token-1000"
921946
}
922947
}
923948
}
924949
}
925950
]
926951
},
927-
"Contents of query are kept after listen is removed.": {
952+
"Contents of query are removed after listen is removed, and GC threshold is reached": {
928953
"describeName": "Garbage Collection:",
929-
"itName": "Contents of query are kept after listen is removed.",
954+
"itName": "Contents of query are removed after listen is removed, and GC threshold is reached",
930955
"tags": [
931956
],
932957
"config": {
@@ -1047,6 +1072,9 @@
10471072
}
10481073
}
10491074
},
1075+
{
1076+
"triggerLruGC": 1
1077+
},
10501078
{
10511079
"userListen": {
10521080
"query": {
@@ -1056,39 +1084,11 @@
10561084
],
10571085
"path": "collection"
10581086
},
1059-
"targetId": 2
1087+
"targetId": 4
10601088
},
1061-
"expectedSnapshotEvents": [
1062-
{
1063-
"added": [
1064-
{
1065-
"createTime": 0,
1066-
"key": "collection/a",
1067-
"options": {
1068-
"hasCommittedMutations": false,
1069-
"hasLocalMutations": false
1070-
},
1071-
"value": {
1072-
"key": "a"
1073-
},
1074-
"version": 1000
1075-
}
1076-
],
1077-
"errorCode": 0,
1078-
"fromCache": true,
1079-
"hasPendingWrites": false,
1080-
"query": {
1081-
"filters": [
1082-
],
1083-
"orderBys": [
1084-
],
1085-
"path": "collection"
1086-
}
1087-
}
1088-
],
10891089
"expectedState": {
10901090
"activeTargets": {
1091-
"2": {
1091+
"4": {
10921092
"queries": [
10931093
{
10941094
"filters": [
@@ -1098,7 +1098,7 @@
10981098
"path": "collection"
10991099
}
11001100
],
1101-
"resumeToken": "resume-token-1000"
1101+
"resumeToken": ""
11021102
}
11031103
}
11041104
}

firebase-firestore/src/test/resources/json/offline_spec_test.json

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1155,7 +1155,8 @@
11551155
"path": "collection/a"
11561156
}
11571157
],
1158-
"resumeToken": ""
1158+
"resumeToken": "",
1159+
"targetPurpose": 2
11591160
},
11601161
"2": {
11611162
"queries": [
@@ -1192,7 +1193,8 @@
11921193
"path": "collection/a"
11931194
}
11941195
],
1195-
"resumeToken": ""
1196+
"resumeToken": "",
1197+
"targetPurpose": 2
11961198
},
11971199
"2": {
11981200
"queries": [

0 commit comments

Comments
 (0)