mirror of
https://github.com/zhigang1992/react-native-firebase.git
synced 2026-01-12 22:50:20 +08:00
tests: jest testing migration crashlytics (#3588)
* tests(crashlytics): migrate JS only tests to Jest * Converted crashlytics tests to ts
This commit is contained in:
@@ -26,6 +26,7 @@ jest.doMock('react-native', () => {
|
||||
],
|
||||
},
|
||||
RNFBPerfModule: {},
|
||||
RNFBCrashlyticsModule: {},
|
||||
},
|
||||
},
|
||||
ReactNative,
|
||||
|
||||
11
packages/crashlytics/__tests__/crashlytics.test.ts
Normal file
11
packages/crashlytics/__tests__/crashlytics.test.ts
Normal file
@@ -0,0 +1,11 @@
|
||||
import { firebase } from '../lib';
|
||||
|
||||
describe('Crashlytics', () => {
|
||||
describe('namespace', () => {
|
||||
it('accessible from firebase.app()', () => {
|
||||
const app = firebase.app();
|
||||
expect(app.crashlytics).toBeDefined();
|
||||
expect(app.crashlytics().app).toEqual(app);
|
||||
});
|
||||
});
|
||||
});
|
||||
@@ -16,14 +16,6 @@
|
||||
*/
|
||||
|
||||
describe('crashlytics()', () => {
|
||||
describe('namespace', () => {
|
||||
it('accessible from firebase.app()', () => {
|
||||
const app = firebase.app();
|
||||
should.exist(app.crashlytics);
|
||||
app.crashlytics().app.should.equal(app);
|
||||
});
|
||||
});
|
||||
|
||||
// Run locally only - flakey on CI
|
||||
xdescribe('crash()', () => {
|
||||
it('crashes the app', async () => {
|
||||
|
||||
Reference in New Issue
Block a user