Skip to content

Commit

Permalink
fix: clear lib directory after running test
Browse files Browse the repository at this point in the history
  • Loading branch information
teclone committed May 7, 2019
1 parent 3658ab9 commit 6f886a4
Show file tree
Hide file tree
Showing 2 changed files with 13 additions and 0 deletions.
6 changes: 6 additions & 0 deletions src/modules/Bundler.ts
Original file line number Diff line number Diff line change
Expand Up @@ -57,6 +57,12 @@ export default class Bundler {
});
}

/**
* pick config from target config or global config
* @param prop config property
* @param targetConfig target config
* @param config global config
*/
private pickConfig(prop: keyof CommonConfig, targetConfig: LibConfig | DistConfig,
config: Config) {
if (prop !== 'include' && prop !== 'exclude') {
Expand Down
7 changes: 7 additions & 0 deletions tests/index.spec.ts
Original file line number Diff line number Diff line change
@@ -1,4 +1,11 @@
import RollupAll from '../src';
import rimraf from 'rimraf';
import * as path from 'path';

afterEach(function () {
rimraf.sync(path.resolve(__dirname, '../dist'));
rimraf.sync(path.resolve(__dirname, '../lib'));
});

describe('Index', function() {

Expand Down

0 comments on commit 6f886a4

Please sign in to comment.