You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository has been archived by the owner on Mar 30, 2021. It is now read-only.
FAIL ./App.test.js
● Test suite failed to run
RNFirebase core module was not found natively on iOS, ensure you have correctly included the RNFirebase pod in your projects `Podfile` and have run `pod install`.
See http://invertase.link/ios for the ios setup guide.
9 | } from 'react-native'
10 |
> 11 | import firebase from 'react-native-firebase'
12 |
13 | export default class App extends React.Component {
14 | constructor () {
Error: RNFirebase core module was not found natively on iOS, ensure you have correctly included the RNFirebase pod in your projects `Podfile` and have run `pod install`.
@mfogel when mocking was recommended it was pre Detox days, now we'd 100% recommend using Detox to run your tests end to end (greybox testing) - you won't need to mock anything and it's as close to real world testing your app as you're gonna get.
If you're looking for an opinionated all-in-one starter kit with Detox baked in + RNFirebase then I'd recommend this one: ueno-llc/react-native-starter - it's great 👌
The goal of this starter kit was to be as raw and close to create-react-native-app's output as possible without you having to fiddle with RNFirebase integrations - no opinions, no bloat etc.
Admittedly Detox integrated with this kit + CI would be awesome and should probably be part of this as standard - we'd love someone to PR this or start the ball rolling on this - will mark this issue as help wanted if anyone wants to pick this up.
After following the getting started instructions, running
npm test
results in an error:This has already been reported in the react-native-firebase repo and it appears this is expected behavior - according to that thread RNFirebase needs to be mocked out for the tests to work.
Assuming that's all correct, I would propose adding a basic mock for RNFirebase to this starter project and enabling it by default.
The text was updated successfully, but these errors were encountered: