mirror of
https://github.com/tenrok/axios.git
synced 2026-05-15 11:59:42 +03:00
Adding nodeunit
This commit is contained in:
+6
-2
@@ -33,6 +33,10 @@ module.exports = function(grunt) {
|
||||
}
|
||||
},
|
||||
|
||||
nodeunit: {
|
||||
all: ['test/unit/*.js']
|
||||
},
|
||||
|
||||
webpack: generateWebpackConfig(),
|
||||
|
||||
watch: {
|
||||
@@ -41,13 +45,13 @@ module.exports = function(grunt) {
|
||||
tasks: ['build']
|
||||
},
|
||||
test: {
|
||||
files: ['lib/**/*.js', 'specs/**/*.js'],
|
||||
files: ['lib/**/*.js', 'test/**/*.js'],
|
||||
tasks: ['test']
|
||||
}
|
||||
}
|
||||
});
|
||||
|
||||
grunt.registerTask('test', ['webpack:global', 'karma:single']);
|
||||
grunt.registerTask('test', ['webpack:global', 'nodeunit', 'karma:single']);
|
||||
grunt.registerTask('build', ['webpack']);
|
||||
grunt.registerTask('publish', ['clean', 'test', 'build', 'update_json']);
|
||||
|
||||
|
||||
+1
-1
@@ -16,7 +16,7 @@ module.exports = function(config) {
|
||||
// list of files / patterns to load in the browser
|
||||
files: [
|
||||
'dist/axios.js',
|
||||
'specs/axios.spec.js'
|
||||
'test/specs/axios.spec.js'
|
||||
],
|
||||
|
||||
|
||||
|
||||
+4
-2
@@ -4,7 +4,8 @@
|
||||
"description": "Lightweight Promise based XHR library",
|
||||
"main": "index.js",
|
||||
"scripts": {
|
||||
"test": "grunt test"
|
||||
"test": "grunt test",
|
||||
"start": "node ./sandbox/index.js"
|
||||
},
|
||||
"repository": {
|
||||
"type": "git",
|
||||
@@ -38,6 +39,7 @@
|
||||
"grunt-karma": "^0.8.3",
|
||||
"karma-phantomjs-launcher": "^0.1.4",
|
||||
"karma-jasmine-ajax": "^0.1.4",
|
||||
"grunt-update-json": "^0.1.3"
|
||||
"grunt-update-json": "^0.1.3",
|
||||
"grunt-contrib-nodeunit": "^0.4.1"
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user