forked from vuejs/vue-cli
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathwdioPlugin.spec.js
41 lines (36 loc) · 1.04 KB
/
wdioPlugin.spec.js
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
jest.setTimeout(process.env.APPVEYOR ? 120000 : 60000)
const create = require('@vue/cli-test-utils/createTestProject')
test('should work', async () => {
const project = await create('e2e-webdriverio', {
plugins: {
'@vue/cli-plugin-babel': {},
'@vue/cli-plugin-e2e-webdriverio': {},
'@vue/cli-plugin-eslint': {
config: 'airbnb',
lintOn: 'save'
}
}
})
if (!process.env.CI) {
await project.run(`vue-cli-service test:e2e`)
} else if (!process.env.APPVEYOR) {
await project.run(`vue-cli-service test:e2e --headless`)
}
})
test('should work with TS', async () => {
const project = await create('e2e-webdriverio-ts', {
plugins: {
'@vue/cli-plugin-typescript': {
'classComponent': true,
'tsLint': true,
'lintOn': ['save']
},
'@vue/cli-plugin-e2e-webdriverio': {}
}
})
if (!process.env.CI) {
await project.run(`vue-cli-service test:e2e`)
} else if (!process.env.APPVEYOR) {
await project.run(`vue-cli-service test:e2e --headless`)
}
})