XCTest:是否可以在 UI 测试自动化中测试 SplashScreen

问题描述 投票:0回答:0

我想知道是否可以在 UI 测试自动化中测试应用程序的启动屏幕。

我的想法是在出现闪屏时断言 1 个 UI 元素,但有时它出现然后消失得太快,UI 测试无法捕获它。

        // Launch the app for the first time
        startFreshApp()
        // Verify that splash screen is opened
        XCTAssert(onboardingPage.splashScreen.waitForExistence(timeout: 20))
xcode xctest xcode-ui-testing automation-testing
© www.soinside.com 2019 - 2024. All rights reserved.