diff --git a/gruntfile.js b/gruntfile.js new file mode 100644 index 0000000..db29b37 --- /dev/null +++ b/gruntfile.js @@ -0,0 +1,20 @@ +module.exports = function(grunt) { + grunt.initConfig({ + pkg: grunt.file.readJSON('package.json'), + + nodeunit: { + all: ['test.js'] + }, + + watch: { + scripts: { + files: ['**/*'], + tasks: ['nodeunit'] + } + } + }); + + grunt.loadNpmTasks('grunt-contrib-nodeunit'); + grunt.loadNpmTasks('grunt-contrib-watch'); + grunt.registerTask('default', ['nodeunit']); +}; diff --git a/package.json b/package.json index f8fed18..9202fb6 100644 --- a/package.json +++ b/package.json @@ -19,7 +19,10 @@ }, "devDependencies": { "mysql": "~2.1.1", - "sqlite3": "~2.1.15" + "sqlite3": "~2.1.15", + "grunt": "~0.4.4", + "grunt-contrib-nodeunit": "~0.3.3", + "grunt-contrib-watch": "~0.6.1" }, "scripts": { "test": "nodeunit test.js" diff --git a/test.js b/test.js index b8b2e24..207c854 100644 --- a/test.js +++ b/test.js @@ -65,7 +65,6 @@ var createTests = function (fig) { this.sql.query( 'SeLECT * FROM TableA', function (err, rows) { - console.log(err); test.deepEqual(rows, [{ id: 2, col: "default"}]); test.done(); }