Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
VueBabe
vuetify
提交
ef36053e
V
vuetify
项目概览
VueBabe
/
vuetify
与 Fork 源项目一致
从无法访问的项目Fork
通知
1
Star
0
Fork
0
代码
文件
提交
分支
Tags
贡献者
分支图
Diff
Issue
0
列表
看板
标记
里程碑
合并请求
0
Wiki
0
Wiki
分析
仓库
DevOps
项目成员
Pages
V
vuetify
项目概览
项目概览
详情
发布
仓库
仓库
文件
提交
分支
标签
贡献者
分支图
比较
Issue
0
Issue
0
列表
看板
标记
里程碑
合并请求
0
合并请求
0
Pages
分析
分析
仓库分析
DevOps
Wiki
0
Wiki
成员
成员
收起侧边栏
关闭侧边栏
动态
分支图
创建新Issue
提交
Issue看板
前往新版Gitcode,体验更适合开发者的 AI 搜索 >>
提交
ef36053e
编写于
5月 11, 2018
作者:
K
Kael
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
create some basic test cases
上级
e33d7456
变更
10
隐藏空白更改
内联
并排
Showing
10 changed file
with
82 addition
and
28 deletion
+82
-28
.gitignore
.gitignore
+2
-0
cypress.json
cypress.json
+10
-1
dev/App.vue
dev/App.vue
+0
-13
dev/e2e/Main.vue
dev/e2e/Main.vue
+5
-0
dev/e2e/cases/VTextField.vue
dev/e2e/cases/VTextField.vue
+17
-0
dev/index.js
dev/index.js
+1
-1
dev/router.js
dev/router.js
+31
-12
package.json
package.json
+1
-1
test/cypress/integration/VTextField.spec.js
test/cypress/integration/VTextField.spec.js
+15
-0
test/cypress/screenshots/my-image.png
test/cypress/screenshots/my-image.png
+0
-0
未找到文件。
.gitignore
浏览文件 @
ef36053e
...
...
@@ -20,3 +20,5 @@ dev/*css
/release
.env
yarn-error.log
/test/cypress/screenshots
/test/cypress/videos
cypress.json
浏览文件 @
ef36053e
{}
{
"baseUrl"
:
"http://localhost:8090/e2e"
,
"testFiles"
:
"**/*.spec.js"
,
"fixturesFolder"
:
"test/cypress/fixtures"
,
"integrationFolder"
:
"test/cypress/integration"
,
"pluginsFile"
:
"test/cypress/plugins/index.js"
,
"screenshotsFolder"
:
"test/cypress/screenshots"
,
"supportFile"
:
"test/cypress/support/index.js"
,
"videosFolder"
:
"test/cypress/videos"
}
dev/App.vue
已删除
100644 → 0
浏览文件 @
e33d7456
<
template
>
<playground></playground>
</
template
>
<
script
>
import
Playground
from
'
./Playground
'
export
default
{
components
:
{
Playground
}
}
</
script
>
dev/e2e/Main.vue
0 → 100644
浏览文件 @
ef36053e
<
template
>
<v-app>
<router-view/>
</v-app>
</
template
>
dev/e2e/cases/VTextField.vue
0 → 100644
浏览文件 @
ef36053e
<
template
>
<v-container>
<v-layout
wrap
>
<v-flex
xs12
v-for=
"field in fields"
:key=
"field"
>
<v-text-field
:label=
"field"
/>
</v-flex>
</v-layout>
</v-container>
</
template
>
<
script
>
export
default
{
data
:
()
=>
({
fields
:
[
'
One
'
,
'
two
'
,
'
three
'
,
'
four
'
,
'
five
'
,
'
six
'
]
})
}
</
script
>
dev/index.js
浏览文件 @
ef36053e
...
...
@@ -13,6 +13,6 @@ Vue.use(VueRouter)
Vue
.
component
(
Boilerplate
.
name
,
Boilerplate
)
new
Vue
({
render
:
h
=>
h
(
App
),
render
:
h
=>
h
(
'
router-view
'
),
router
}).
$mount
(
'
#app
'
)
dev/router.js
浏览文件 @
ef36053e
import
VueRouter
from
'
vue-router
'
const
component1
=
{
template
:
`<div class="title">Page 1</div>`
}
const
component2
=
{
template
:
`<div class="title">Page 2</div>`
const
testCases
=
require
.
context
(
'
./e2e/cases
'
,
false
,
/
\.
vue$/
)
.
keys
()
.
map
(
k
=>
k
.
substring
(
2
))
.
map
(
k
=>
[
k
.
slice
(
0
,
-
4
),
import
(
`./e2e/cases/
${
k
}
`
)])
function
component
(
text
)
{
return
{
render
:
h
=>
h
(
'
div
'
,
{
staticClass
:
'
title
'
},
[
text
])
}
}
const
router
=
new
VueRouter
({
mode
:
'
history
'
,
routes
:
[
{
path
:
'
/page1
'
,
name
:
'
Page 1
'
,
component
:
component1
},
path
:
'
/
'
,
component
:
()
=>
import
(
'
./Playground.vue
'
),
children
:
[
{
path
:
'
page1
'
,
name
:
'
Page 1
'
,
component
:
component
(
'
Page 1
'
)
},
{
path
:
'
page2
'
,
name
:
'
Page 2
'
,
component
:
component
(
'
Page 2
'
)
},
]
}
{
path
:
'
/page2
'
,
name
:
'
Page 2
'
,
component
:
component2
path
:
'
/e2e
'
,
component
:
()
=>
import
(
'
./e2e/Main.vue
'
)
children
:
testCases
.
map
(
c
=>
({
path
:
c
[
0
],
component
:
()
=>
c
[
1
]
}))
},
{
path
:
'
*
'
,
redirect
:
'
/page1
'
}
]
...
...
package.json
浏览文件 @
ef36053e
...
...
@@ -14,7 +14,7 @@
"types"
:
"types/index.d.ts"
,
"scripts"
:
{
"watch"
:
"cross-env TARGET=development webpack --config build/config.js --progress --hide-modules --watch"
,
"dev"
:
"cross-env NODE_ENV=development webpack-dev-server --config build/webpack.dev.config.js --
open --hot
"
,
"dev"
:
"cross-env NODE_ENV=development webpack-dev-server --config build/webpack.dev.config.js --
hot --history-api-fallback
"
,
"build"
:
"yarn build:dist && yarn build:es5"
,
"build:dev"
:
"cross-env NODE_ENV=production node build/webpack.dev.config.js"
,
"build:dist"
:
"rimraf dist && cross-env NODE_ENV=production webpack --config build/config.js --progress --hide-modules"
,
...
...
test/cypress/integration/VTextField.spec.js
0 → 100644
浏览文件 @
ef36053e
describe
(
'
VTextField
'
,
()
=>
{
beforeEach
(()
=>
{
cy
.
visit
(
'
/VtextField
'
)
cy
.
wait
(
100
)
})
it
(
'
should work
'
,
()
=>
{
cy
.
get
(
'
.v-text-field
'
).
each
(
f
=>
(
cy
.
wrap
(
f
).
click
().
get
(
'
:focus
'
).
type
(
'
Hello world
'
)
))
cy
.
contains
(
'
two
'
).
click
()
cy
.
get
(
'
:focus
'
).
type
(
'
{selectall}second input
'
)
})
})
test/cypress/screenshots/my-image.png
已删除
100644 → 0
浏览文件 @
e33d7456
175.5 KB
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录