提交 | 用户 | age
|
36e1de
|
1 |
// For authoring Nightwatch tests, see |
L |
2 |
// http://nightwatchjs.org/guide#usage |
|
3 |
|
|
4 |
module.exports = { |
|
5 |
'default e2e tests': function (browser) { |
|
6 |
// automatically uses dev Server port from /config.index.js |
|
7 |
// default: http://localhost:8080 |
|
8 |
// see nightwatch.conf.js |
|
9 |
const devServer = browser.globals.devServerURL |
|
10 |
|
|
11 |
browser |
|
12 |
.url(devServer) |
|
13 |
.waitForElementVisible('#app', 5000) |
|
14 |
.assert.elementPresent('.hello') |
|
15 |
.assert.containsText('h1', 'Welcome to Your Vue.js App') |
|
16 |
.assert.elementCount('img', 1) |
|
17 |
.end() |
|
18 |
} |
|
19 |
} |