Skip to content

Commit

Permalink
fix(fsshopify): fix shopifydatasource test
Browse files Browse the repository at this point in the history
The new version of react-native-payments introduced by Greenkeeper uses ReactNative.requireNativeComponent to import native UI widgets. Because the ShopifyDataSource test mocks react-native, we need to mock this method as well to prevent the test from erroring.
  • Loading branch information
bweissbart committed Jul 3, 2018
1 parent 56923d6 commit 9b3f5f4
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions packages/fsshopify/src/__tests__/ShopifyDataSource.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@ const mockDirName = __dirname;
jest.mock('react-native', () => {
return {
default: {},
requireNativeComponent: () => false,
NativeModules: {
ReactNativePayments: {}
},
Expand Down

0 comments on commit 9b3f5f4

Please sign in to comment.