Initial Grunt architecture

This commit is contained in:
grosbouddha 2013-05-26 23:58:59 +02:00
parent 918d84545a
commit d794301301
3 changed files with 73 additions and 14 deletions

48
Gruntfile.js Normal file
View File

@ -0,0 +1,48 @@
grunt.loadNpmTasks('grunt-contrib-connect');
grunt.loadNpmTasks('grunt-contrib-jshint');
//grunt.loadNpmTasks('grunt-contrib-nodeunit');
grunt.loadNpmTasks('grunt-ghost');
grunt.registerTask('test', ['jshint', /*'nodeunit',*/ 'connect', 'ghost']);
jshint: {
/*options: {
jshintrc: '.jshintrc'
},*/
files: [
'Gruntfile.js',
'package.json',
'source/**/*.js'/*,
'<%= nodeunit.tests %>'*/
]
},
/*
nodeunit: {
tests: ['tests/nodeunit/*_test.js']
},
*/
connect: {
www: {
options: {
base: 'source',
port: 4545
}
}
},
ghost: {
test: {
files: [{
src: ['tests/integration/casperjs/*_test.js']
}]
},
options: {
args: {
baseUrl: 'http://localhost:' +
'<%= connect.www.options.port %>/'
},
direct: false,
logLevel: 'error',
printCommand: false,
printFilePaths: true
}
}

View File

@ -8,8 +8,18 @@
"type": "git",
"url": "http://github.com/juliandescottes/piskel.git"
},
"scripts": { "test": "make test" },
"scripts": {
"test": "grunt test"
//"test": "make test"
},
"devDependencies": {
"jshint": "0.6.1"
//"jshint": "0.6.1",
"grunt": "0.4.1",
// Grunt task to start a web server:
"grunt-contrib-connect": "0.3.0",
"grunt-contrib-jshint": "0.5.4",
//"grunt-contrib-nodeunit": "0.1.2",
// Grunt task to run CasperJS tests:
"grunt-ghost": "1.0.12"
}
}

View File

@ -0,0 +1 @@
// pouet