Skip to content

Commit

Permalink
add failing test
Browse files Browse the repository at this point in the history
  • Loading branch information
magicmark committed Jun 30, 2017
1 parent 4d5dcc6 commit f1de0ed
Show file tree
Hide file tree
Showing 3 changed files with 20 additions and 0 deletions.
8 changes: 8 additions & 0 deletions __tests__/commands/install/integration.js
Original file line number Diff line number Diff line change
Expand Up @@ -883,3 +883,11 @@ test.concurrent('transitive file: dependencies should work', (): Promise<void> =
expect(await fs.exists(path.join(config.cwd, 'node_modules', 'b'))).toBe(true);
});
});

test.concurrent('unbound transitive dependencies should not conflict with top level dependency', async () => {
await runInstall({flat: true}, 'install-conflicts', async config => {
expect((await fs.readJson(path.join(config.cwd, 'node_modules', 'left-pad', 'package.json'))).version).toEqual(
'1.0.0',
);
});
});
6 changes: 6 additions & 0 deletions __tests__/fixtures/install/install-conflicts/b/package.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
{
"version": "0.0.1",
"dependencies": {
"left-pad": ">=0.0.1"
}
}
6 changes: 6 additions & 0 deletions __tests__/fixtures/install/install-conflicts/package.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
{
"dependencies": {
"b": "file:b",
"left-pad": "1.0.0"
}
}

0 comments on commit f1de0ed

Please sign in to comment.