Skip to content

Commit

Permalink
Merge pull request #112 from mkmelin/wintmpdir-test
Browse files Browse the repository at this point in the history
Make the creation_api_spec test work on Windows, by using system tempdir instead of /tmp/.
  • Loading branch information
mcollina committed Apr 1, 2015
2 parents 9b588e4 + 2405d1f commit 703c19d
Showing 1 changed file with 5 additions and 2 deletions.
7 changes: 5 additions & 2 deletions test/creation_api_spec.js
@@ -1,6 +1,8 @@

var levelgraph = require('../lib/levelgraph')
, level = require('level-test')();
, level = require('level-test')(),
os = require('os'),
path = require('path');

describe('creation api', function() {

Expand All @@ -18,6 +20,7 @@ describe('creation api', function() {
});

it('should create a db passing a string', function() {
db = levelgraph('/tmp/hello');
var dbPath = path.join(os.tmpdir(), 'hello');
db = levelgraph(dbPath);
});
});

0 comments on commit 703c19d

Please sign in to comment.