soumak77 / firebase-mock

Firebase mock library for writing unit tests
https://soumak77.github.io/firebase-mock
349 stars 97 forks source link

Issues with Jest #153

Open Emiliano-Bucci opened 5 years ago

Emiliano-Bucci commented 5 years ago

Good evening to all! I'm working on a Next.JS + typescript application and i start to use Firebase. I'm finding issues with jest. Without this lib i keep getting this:

 Test suite failed to run

    TypeError: Cannot read property 'fromJSON' of undefined

      1 | import firebase from "firebase/app";
    > 2 | import "firebase/firestore";
        | ^
      3 | import "firebase/auth";
      4 | import {
      5 |   LogTypes,

and with the use of this lib, mostly the same. Is possible that Firebase team don't think on this kind of environments? Anyone knows why?