mirror of
https://github.com/status-im/react-native.git
synced 2025-01-23 16:00:37 +00:00
21 lines
567 B
JavaScript
21 lines
567 B
JavaScript
|
'use strict';
|
||
|
|
||
|
jest.autoMockOff();
|
||
|
|
||
|
const path = require('path');
|
||
|
const isInstalled = require('../../src/android/isInstalled');
|
||
|
|
||
|
const projectConfig = {
|
||
|
buildGradlePath: path.join(__dirname, '../../__fixtures__/android/patchedBuild.gradle'),
|
||
|
};
|
||
|
|
||
|
describe('android::isInstalled', () => {
|
||
|
it('should return true when project is already in build.gradle', () =>
|
||
|
expect(isInstalled(projectConfig, 'test')).toBeTruthy()
|
||
|
);
|
||
|
|
||
|
it('should return false when project is not in build.gradle', () =>
|
||
|
expect(isInstalled(projectConfig, 'test2')).toBeFalsy()
|
||
|
);
|
||
|
});
|