Skip to content

Commit

Permalink
fix tests
Browse files Browse the repository at this point in the history
  • Loading branch information
sindresorhus committed Mar 5, 2016
1 parent d1053c9 commit 1372baa
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 3 deletions.
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,7 @@
},
"devDependencies": {
"ava": "*",
"tempdir": "^1.0.0",
"tempfile": "^1.1.1",
"xo": "*"
}
}
6 changes: 4 additions & 2 deletions test.js
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
import test from 'ava';
import fs from 'fs';
import path from 'path';
import tempdir from 'tempdir';
import tempfile from 'tempfile';
import fn from './';

const pkgPath = path.resolve('.', 'package.json');
Expand All @@ -10,7 +10,9 @@ const fixture = path.join('.', 'fixture', 'foo', 'bar');

// Create a disjoint directory, used for the not-found tests.
test.beforeEach(async t => {
t.context.disjoint = await tempdir();
const tmpDir = tempfile();
fs.mkdirSync(tmpDir);
t.context.disjoint = tmpDir;
});

test.afterEach(t => {
Expand Down

0 comments on commit 1372baa

Please sign in to comment.