mirror of
https://github.com/zhigang1992/react-native.git
synced 2026-04-30 05:55:48 +08:00
Allow custom platforms for the RN Packager on a per-project basis
Reviewed By: cpojer Differential Revision: D4255979 fbshipit-source-id: bf900b67ee30e2f994e96c9a6103ed2e53a87f88
This commit is contained in:
committed by
Facebook Github Bot
parent
59dd2133cb
commit
67828a52bd
@@ -107,6 +107,15 @@ describe('Resolver', function() {
|
||||
});
|
||||
});
|
||||
|
||||
it('passes custom platforms to the dependency graph', function() {
|
||||
new Resolver({ // eslint-disable-line no-new
|
||||
projectRoot: '/root',
|
||||
platforms: ['ios', 'windows', 'vr'],
|
||||
});
|
||||
const platforms = DependencyGraph.mock.calls[0][0].platforms;
|
||||
expect(platforms).toEqual(['ios', 'windows', 'vr']);
|
||||
});
|
||||
|
||||
pit('should get dependencies with polyfills', function() {
|
||||
var module = createModule('index');
|
||||
var deps = [module];
|
||||
|
||||
Reference in New Issue
Block a user