From d93d965d426fb5f6dc29c44cf6502cbb006c80ba Mon Sep 17 00:00:00 2001 From: milaGGL <107142260+milaGGL@users.noreply.github.com> Date: Thu, 27 Oct 2022 12:36:34 -0700 Subject: [PATCH] resolve comments --- .../test/integration/api/transactions.test.ts | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/packages/firestore/test/integration/api/transactions.test.ts b/packages/firestore/test/integration/api/transactions.test.ts index 2d7f56596f1..6126e9f9cb8 100644 --- a/packages/firestore/test/integration/api/transactions.test.ts +++ b/packages/firestore/test/integration/api/transactions.test.ts @@ -636,11 +636,11 @@ apiDescribe('Database transactions', (persistence: boolean) => { await runTransaction(db, async transaction => { ++retryCounter; - const snap1 = await transaction.get(docRef); + const snap = await transaction.get(docRef); if (retryCounter === 1) { - expect(snap1.exists()).to.be.false; - // On the first attemp, create a doc before transaction.set(), so that + expect(snap.exists()).to.be.false; + // On the first attempt, create a doc before transaction.set(), so that // the transaction fails with "already-exists" error, and retries. await setDoc(docRef, { count: 1 }); } @@ -648,8 +648,8 @@ apiDescribe('Database transactions', (persistence: boolean) => { transaction.set(docRef, { count: 2 }); }); expect(retryCounter).to.equal(2); - const result = await getDoc(docRef); - expect(result.get('count')).to.equal(2); + const snap = await getDoc(docRef); + expect(snap.get('count')).to.equal(2); }); });