Fix test build errors: isCacheValid ttlMs parameter and screen object name conflicts

SKIE doesn't expose Kotlin default parameters to Swift, so isCacheValid calls
need explicit ttlMs argument. Renamed struct-based screen objects to avoid
ambiguity with class-based PageObjects (LoginScreenObject, RegisterScreenObject,
MainTabScreenObject).

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
This commit is contained in:
treyt
2026-02-24 15:59:48 -06:00
parent 786a9c6fb6
commit 4679764fdf
10 changed files with 24 additions and 24 deletions

View File

@@ -67,7 +67,7 @@ struct VerificationScreen {
}
}
struct MainTabScreen {
struct MainTabScreenObject {
let app: XCUIApplication
var tabBar: XCUIElement { app.tabBars.firstMatch }
@@ -160,13 +160,13 @@ struct ResidenceFormScreen {
enum RebuildSessionAssertions {
static func assertOnLogin(_ app: XCUIApplication, timeout: TimeInterval = 15, file: StaticString = #filePath, line: UInt = #line) {
let login = LoginScreen(app: app)
let login = LoginScreenObject(app: app)
login.waitForLoad(timeout: timeout)
XCTAssertTrue(app.textFields[UITestID.Auth.usernameField].exists, "Expected login state", file: file, line: line)
}
static func assertOnMainApp(_ app: XCUIApplication, timeout: TimeInterval = 15, file: StaticString = #filePath, line: UInt = #line) {
let main = MainTabScreen(app: app)
let main = MainTabScreenObject(app: app)
main.waitForLoad(timeout: timeout)
XCTAssertTrue(
app.otherElements[UITestID.Root.mainTabs].exists || main.tabBar.exists,