File tree 2 files changed +14
-1
lines changed
examples/sites/demos/pc/app/sticky
2 files changed +14
-1
lines changed Original file line number Diff line number Diff line change 1
1
name : E2E Test Dispatch
2
- run-name : E2E Test Dispatch--${{ inputs.testDemos }}--
2
+ run-name : E2E Test Dispatch--${{ inputs.testDemos }}--origin--${{ inputs.origin }}
3
3
on :
4
4
workflow_dispatch :
5
5
inputs :
9
9
such as `input, alert`.
10
10
required : true
11
11
type : string
12
+ origin :
13
+ description : |
14
+ 输入需要测试的域名地址,包括微服务路径,如果不输入则采用本地启动服务测试,
15
+ 例如: `https://opentiny.github.io/tiny-vue-web-doc`.
16
+ required : false
17
+ type : string
12
18
concurrency :
13
19
group : ${{ github.workflow }}-${{ github.sha }}
14
20
cancel-in-progress : true
44
50
run : pnpm i --no-frozen-lockfile
45
51
46
52
- name : dev start
53
+ if : contains(inputs.origin, 'http') == false
47
54
run : pnpm site & sleep 5
48
55
56
+ - name : Release E2E Config
57
+ if : contains(inputs.origin, 'http') == true
58
+ run : pnpm release:e2eConfig -o ${{ inputs.origin }} & sleep 5
59
+
49
60
- name : Install Playwright browsers
50
61
run : pnpm install:browser --with-deps chromium
51
62
Original file line number Diff line number Diff line change @@ -7,5 +7,7 @@ test('偏移距离', async ({ page }) => {
7
7
const demo = page . locator ( '#offset' )
8
8
9
9
await demo . locator ( 'i' ) . first ( ) . scrollIntoViewIfNeeded ( )
10
+ await page . waitForTimeout ( 200 )
11
+ await demo . locator ( 'i' ) . nth ( 2 ) . scrollIntoViewIfNeeded ( )
10
12
await expect ( demo . locator ( '.tiny-sticky--fixed' ) ) . toHaveCSS ( 'top' , '100px' )
11
13
} )
You can’t perform that action at this time.
0 commit comments