react-native/Libraries/BatchedBridge/BatchedBridgedModules/__mocks__/NativeModules.js

61 lines
1.1 KiB
JavaScript
Raw Normal View History

/**
* Copyright 2004-present Facebook. All Rights Reserved.
*/
'use strict';
var NativeModules = {
I18n: {
translationsDictionary: JSON.stringify({
'Good bye, {name}!|Bye message': '¡Adiós {name}!',
}),
},
Timing: {
createTimer: jest.fn(),
deleteTimer: jest.fn(),
},
GraphPhotoUpload: {
upload: jest.fn(),
},
FacebookSDK: {
login: jest.fn(),
logout: jest.fn(),
queryGraphPath: jest.fn((path, method, params, callback) => callback()),
},
DataManager: {
queryData: jest.fn(),
},
UIManager: {
customBubblingEventTypes: {},
customDirectEventTypes: {},
Dimensions: {},
2015-09-01 00:34:51 +00:00
RCTModalFullscreenView: {
Constants: {},
},
RCTScrollView: {
Constants: {},
},
},
AsyncLocalStorage: {
getItem: jest.fn(),
setItem: jest.fn(),
removeItem: jest.fn(),
clear: jest.fn(),
},
SourceCode: {
scriptURL: null,
},
BuildInfo: {
appVersion: '0',
buildVersion: '0',
},
2015-09-01 00:34:51 +00:00
ModalFullscreenViewManager: {},
AlertManager: {
alertWithArgs: jest.fn(),
2015-09-01 00:34:51 +00:00
},
Clipboard: {
setString: jest.fn(),
2015-09-01 00:34:51 +00:00
},
};
module.exports = NativeModules;