-
Notifications
You must be signed in to change notification settings - Fork 664
Closed
Description
Do you want to request a feature or report a bug?
Feature
What is the current behavior?
I'm removing a test from DependencyGraph-test
that looked like so, but wasn't actually working after I fixed problems with the fs
mocks:
it('should work with packages with symlinked subdirs', function() {
var root = '/root';
setMockFileSystem({
'symlinkedPackage': {
'package.json': JSON.stringify({
name: 'aPackage',
main: 'main.js',
}),
'main.js': 'lol',
'subdir': {
'lolynot.js': 'lolynot',
},
},
'root': {
'index.js': [
'/**',
' * @providesModule index',
' */',
'require("aPackage/subdir/lolynot")',
].join('\n'),
'aPackage': { SYMLINK: '/symlinkedPackage' },
},
});
var dgraph = new DependencyGraph({
...defaults,
roots: [root],
});
return getOrderedDependenciesAsJSON(dgraph, '/root/index.js').then(function(deps) {
expect(deps)
.toEqual([
{
id: 'index',
path: '/root/index.js',
dependencies: ['aPackage/subdir/lolynot'],
isAsset: false,
isJSON: false,
isPolyfill: false,
resolution: undefined,
resolveDependency: undefined,
},
{
id: 'aPackage/subdir/lolynot.js',
path: '/root/aPackage/subdir/lolynot.js',
dependencies: [],
isAsset: false,
isJSON: false,
isPolyfill: false,
resolution: undefined,
resolveDependency: undefined,
},
]);
});
});
What is the expected behavior?
Reintroduce the test and verify symlinks work.
dzannotti, slorber, christopherpetro, piuccio, matt-oakes and 282 moreHarishn28, kj800x, voluntas, nicbarker, mxmzb and 9 moreStephen2, nicbarker, evgeny-belyaev, mxmzb, fjmoralesp and 15 morebrody4hire, phsantiago, ma-shop, abouquet, lukeramsden and 5 more
Metadata
Metadata
Assignees
Labels
No labels