We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 12f19e8 commit a011e40Copy full SHA for a011e40
test/bind.spec.js
@@ -100,6 +100,26 @@ test('waits for all refs in document', async () => {
100
})
101
102
103
+test('waits for all refs in document with interrupting by new ref', async () => {
104
+ const a = db.collection().doc()
105
+ const b = db.collection().doc()
106
+ const c = db.collection().doc()
107
+ delayUpdate(b)
108
+ await document.update({ a, b })
109
+
110
+ const promise = vm.$bind('item', document)
111
112
+ document.update({ c })
113
114
+ await promise
115
116
+ expect(vm.item).toEqual({
117
+ a: null,
118
+ b: null,
119
+ c: null
120
+ })
121
+})
122
123
test('waits for all refs in collection', async () => {
124
const a = db.collection().doc()
125
const b = db.collection().doc()
0 commit comments