Properly remove seed test file to prevent jshint warning

This commit is contained in:
Tim Griesser 2014-09-03 16:09:20 -04:00
parent eec5bdc4f6
commit d77debbaa8
2 changed files with 2 additions and 12 deletions

View File

@ -1,4 +1,4 @@
/*global after, describe, it, expect*/
/*global describe, it, expect*/
'use strict';
var path = require('path');
@ -6,11 +6,10 @@ var rimraf = require('rimraf');
module.exports = function(knex) {
require('rimraf').sync(path.join(__dirname, './seed'));
describe('knex.seed.make', function() {
it('should create a new seed file with the make method', function () {
return knex.seed.make('test').then(function (name) {
rimraf.sync(path.dirname(name));
expect(path.basename(name)).to.equal('test.js');
});
});
@ -25,8 +24,4 @@ module.exports = function(knex) {
});
});
after(function() {
rimraf.sync(path.join(__dirname, './seed'));
});
};

View File

@ -1,5 +0,0 @@
'use strict';
exports.seed = function(knex) {
knex('tableName').insert({colName: 'rowValue'});
};