Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merge main UI Tests Update to NetworkFix feature #9

Merged
merged 3 commits into from
Nov 18, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions .github/workflows/ios.yml
Original file line number Diff line number Diff line change
Expand Up @@ -20,8 +20,8 @@ jobs:

- name: Archive DarockBili App
run: |
xcodebuild -scheme DarockBili -configuration Debug DEVELOPMENT_TEAM=B57D8PP775 -sdk 'iphoneos' -destination 'generic/platform=iOS' -archivePath DarockBili_Debug.xcarchive clean archive CODE_SIGN_IDENTITY=""
xcodebuild -scheme DarockBili -configuration Release DEVELOPMENT_TEAM=B57D8PP775 -sdk 'iphoneos' -destination 'generic/platform=iOS' -archivePath DarockBili_Release.xcarchive clean archive CODE_SIGN_IDENTITY=""
xcodebuild -scheme 'DarockBili Watch App' -configuration Debug -archivePath DarockBili_Debug.xcarchive clean archive CODE_SIGN_IDENTITY=""
xcodebuild -scheme 'DarockBili Watch App' -configuration Release -archivePath DarockBili_Release.xcarchive clean archive CODE_SIGN_IDENTITY=""

- name: Export IPA
run: |
Expand Down
17 changes: 14 additions & 3 deletions DarockBili Watch App UI Tests/DarockBili_Watch_App_UI_Tests.swift
Original file line number Diff line number Diff line change
Expand Up @@ -28,12 +28,23 @@ final class DarockBili_Watch_App_UI_Tests: XCTestCase {
app.launch()

takeScreenshot(of: app, named: "Launch")

app.buttons["SuggestVideo"].firstMatch.tap()
sleep(1)
takeScreenshot(of: app, named: "RMVideo")
app.swipeUp()
sleep(1)
takeScreenshot(of: app, named: "RMVideoP2")
app.navigationBars.buttons.element(boundBy: 0).tap()
sleep(1)
app.otherElements["MainTabView"].swipeLeft()
sleep(1)
takeScreenshot(of: app, named: "PersonalCenter")
app.buttons["AppSettingsButton"].firstMatch.tap()

takeScreenshot(of: app, named: "PC")
sleep(1)
takeScreenshot(of: app, named: "SettingsMain")
app.buttons["以太网"].firstMatch.tap()
sleep(1)
takeScreenshot(of: app, named: "EthernetSetting")
}

func testLaunchPerformance() throws {
Expand Down
2 changes: 1 addition & 1 deletion DarockBili Watch App/InMain/MainView.swift
Original file line number Diff line number Diff line change
Expand Up @@ -98,7 +98,7 @@ struct MainView: View {
autoreleasepool {
ForEach(0...videos.count - 1, id: \.self) { i in
VideoCard(videos[i])
.accessibilityIdentifier(i == 0 ? "TestVideoCard" : "")
.accessibility(identifier: "SuggestVideo")
}
}
}
Expand Down
Loading