2
0
mirror of synced 2025-02-20 18:18:10 +00:00

[tests][firestore] remove logging

This commit is contained in:
Salakar 2018-04-16 17:47:50 +01:00
parent 8b683f643b
commit 60634ae68e

View File

@ -15,17 +15,14 @@ describe('firestore()', () => {
it('should delete a field', async () => { it('should delete a field', async () => {
const { data } = await testCollectionDoc(DOC_2_PATH).get(); const { data } = await testCollectionDoc(DOC_2_PATH).get();
should.equal(data().title, DOC_2.title); should.equal(data().title, DOC_2.title);
console.log('after 1st get');
await testCollectionDoc(DOC_2_PATH).update({ await testCollectionDoc(DOC_2_PATH).update({
title: firebase.firestore.FieldValue.delete(), title: firebase.firestore.FieldValue.delete(),
}); });
console.log('after update');
const { data: dataAfterUpdate } = await testCollectionDoc( const { data: dataAfterUpdate } = await testCollectionDoc(
DOC_2_PATH DOC_2_PATH
).get(); ).get();
console.log('after 2nd get');
should.equal(dataAfterUpdate().title, undefined); should.equal(dataAfterUpdate().title, undefined);
}); });
@ -35,17 +32,14 @@ describe('firestore()', () => {
it('should set timestamp', async () => { it('should set timestamp', async () => {
const { data } = await testCollectionDoc(DOC_2_PATH).get(); const { data } = await testCollectionDoc(DOC_2_PATH).get();
should.equal(data().creationDate, undefined); should.equal(data().creationDate, undefined);
console.log('after 1st get');
await testCollectionDoc(DOC_2_PATH).update({ await testCollectionDoc(DOC_2_PATH).update({
creationDate: firebase.firestore.FieldValue.serverTimestamp(), creationDate: firebase.firestore.FieldValue.serverTimestamp(),
}); });
console.log('after update');
const { data: dataAfterUpdate } = await testCollectionDoc( const { data: dataAfterUpdate } = await testCollectionDoc(
DOC_2_PATH DOC_2_PATH
).get(); ).get();
console.log('after 2nd get');
dataAfterUpdate().creationDate.should.be.instanceof( dataAfterUpdate().creationDate.should.be.instanceof(
bridge.context.window.Date bridge.context.window.Date