diff --git a/tests/.babelrc b/tests/.babelrc index d6ff3f1b..0c5dcafa 100644 --- a/tests/.babelrc +++ b/tests/.babelrc @@ -1,5 +1,16 @@ { "presets": [ "react-native" - ] + ], + "env": { + "development": { + "plugins": [ + ["istanbul", { + "include": [ + "**/firebase/**.js" + ] + }] + ] + } + } } diff --git a/tests/src/tests/index.js b/tests/src/tests/index.js index 85d1a390..2c37f002 100644 --- a/tests/src/tests/index.js +++ b/tests/src/tests/index.js @@ -10,6 +10,10 @@ import config from './config/index'; import performance from './perf/index'; import admob from './admob/index'; +window.getCoverage = function getCoverage() { + return (JSON.stringify(global.__coverage__)); +}; + const testSuiteInstances = [ database, auth,