1
0
Fork 0

fix(build): move sinon to vendor chunk

This commit is contained in:
ssube 2019-06-30 18:43:52 -05:00
parent 31d1977f3b
commit d02b223c6d
Signed by: ssube
GPG Key ID: 3EED7B957D362AF1
2 changed files with 8 additions and 6 deletions

View File

@ -9,18 +9,21 @@ const metadata = require('../package.json');
const shebang = '#! /usr/bin/env node';
const bundle = {
external: [
'dtrace-provider',
],
input: [
'src/index.ts',
'test/harness.ts',
'test/**/Test*.ts',
],
manualChunks(id) {
if (id.includes('/node_modules/')) {
return 'vendor';
if (id.includes('/test/') /* || id.includes('/chai/') */ || id.includes('/sinon/')) {
return 'test'
}
if (id.includes('/test/')) {
return 'test'
if (id.includes('/node_modules/')) {
return 'vendor';
}
if (id.includes('/src/index')) {

View File

@ -159,6 +159,5 @@ describe('rule visitor', () => {
mockRule.verify();
expect(ctx.errors.length).to.equal(0);
})
});
});