Skip to content

Commit

Permalink
feat(ui): nightwatch task
Browse files Browse the repository at this point in the history
  • Loading branch information
Guillaume Chau committed May 11, 2018
1 parent 69a817e commit 76f95c8
Show file tree
Hide file tree
Showing 2 changed files with 26 additions and 0 deletions.
18 changes: 18 additions & 0 deletions packages/@vue/cli-plugin-e2e-nightwatch/ui.js
@@ -0,0 +1,18 @@
module.exports = api => {
api.describeTask({
match: /vue-cli-service test:e2e/,
description: 'nightwatch.tasks.test.description',
link: 'https://github.com/vuejs/vue-cli/tree/dev/packages/%40vue/cli-plugin-e2e-nightwatch#injected-commands',
prompts: [
{
name: 'url',
type: 'input',
default: '',
description: 'nightwatch.tasks.test.url'
}
],
onBeforeRun: ({ answers, args }) => {
if (answers.url) args.push('--url', answers.url)
}
})
}
8 changes: 8 additions & 0 deletions packages/@vue/cli/locales/en.json
Expand Up @@ -453,5 +453,13 @@
"url": "Run e2e tests against given url instead of auto-starting dev server"
}
}
},
"nightwatch": {
"tasks": {
"test": {
"description": "Run e2e tests with nightwatch",
"url": "Run e2e tests against given url instead of auto-starting dev server"
}
}
}
}

0 comments on commit 76f95c8

Please sign in to comment.