Skip to content

Commit 72e8e73

Browse files
committed
organize grunt tasks
1 parent 789adff commit 72e8e73

File tree

2 files changed

+16
-7
lines changed

2 files changed

+16
-7
lines changed

Gruntfile.js

Lines changed: 14 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@ module.exports = function( grunt ) {
1717
src: '.',
1818
dest: 'dist'
1919
},
20-
test: {
20+
unit: {
2121
options: {
2222
name: 'vue.test'
2323
},
@@ -87,18 +87,27 @@ module.exports = function( grunt ) {
8787
})
8888

8989
grunt.registerTask( 'build', [
90-
'componentbuild',
90+
'componentbuild:build',
9191
'uglify',
9292
'size'
9393
])
9494

95-
grunt.registerTask( 'test', [
96-
'componentbuild',
95+
grunt.registerTask( 'unit', [
96+
'componentbuild:unit',
9797
'jsc',
98-
'mocha',
98+
'mocha'
99+
])
100+
101+
grunt.registerTask( 'e2e', [
102+
'componentbuild:build',
99103
'casper'
100104
])
101105

106+
grunt.registerTask( 'test', [
107+
'unit',
108+
'e2e'
109+
])
110+
102111
grunt.registerTask( 'default', [
103112
'jshint',
104113
'test',

test/functional/specs/expression.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -18,15 +18,15 @@ casper.test.begin('Expression', 19, function (test) {
1818
})
1919
.then(function () {
2020
test.assertSelectorHasText('#normal p', 'Hola World!')
21-
test.assertField('one', 'Hola')
21+
test.assertField('one', 'Hola')
2222
})
2323
.thenEvaluate(function () {
2424
// setting nested value
2525
normal.two.three = 'Casper'
2626
})
2727
.then(function () {
2828
test.assertSelectorHasText('#normal p', 'Hola Casper!')
29-
test.assertField('two', 'Casper')
29+
test.assertField('two', 'Casper')
3030
})
3131
.then(function () {
3232
// lazy input

0 commit comments

Comments
 (0)