transition-events.test.js 753 字节
Newer Older
张磊 已提交
1 2 3 4 5
// uni-app自动化测试教程: uni-app自动化测试教程: https://uniapp.dcloud.net.cn/worktile/auto/hbuilderx-extension/

describe('transition event', () => {
    let page;
    beforeAll(async () => {
6
        page = await program.reLaunch('/pages/component/public-events/transition-events')
张磊 已提交
7 8 9 10 11 12 13
        await page.waitFor(3000);
    });

    it('transitionend', async () => {
        await page.callMethod('switchBtn')
        await page.waitFor(3000)
        expect(await page.data("onTransitionEndTriggr")).toBe(true)
张磊 已提交
14 15 16 17 18
        await page.callMethod('switchBtn')
        await page.waitFor(200)
        await page.callMethod('switchBtn')
        await page.waitFor(3000)
        expect(await page.data("onTransitionEndTriggr")).toBe(true)
张磊 已提交
19 20
    });
});