mirror of
https://github.com/SideStore/SideStore.git
synced 2026-02-08 22:33:26 +01:00
UITests: added more idling waits since we removed(mocked) quiescent idling wait from testing framework at runtime.
This commit is contained in:
@@ -55,7 +55,7 @@ final class UITests: XCTestCase {
|
|||||||
// printAllMethods(of: "XCUIApplicationProcess")
|
// printAllMethods(of: "XCUIApplicationProcess")
|
||||||
|
|
||||||
// Put setup code here. This method is called before the invocation of each test method in the class.
|
// Put setup code here. This method is called before the invocation of each test method in the class.
|
||||||
// Self.dismissSpotlight()
|
Self.dismissSpotlight()
|
||||||
// Self.deleteMyApp()
|
// Self.deleteMyApp()
|
||||||
Self.deleteMyApp2()
|
Self.deleteMyApp2()
|
||||||
|
|
||||||
@@ -81,7 +81,9 @@ final class UITests: XCTestCase {
|
|||||||
|
|
||||||
// if it exists keep going immediately else wait for upto 5 sec with polling every 1 sec for existence
|
// if it exists keep going immediately else wait for upto 5 sec with polling every 1 sec for existence
|
||||||
XCTAssertTrue(systemAlert.exists || systemAlert.waitForExistence(timeout: 5), "Notifications alert did not appear")
|
XCTAssertTrue(systemAlert.exists || systemAlert.waitForExistence(timeout: 5), "Notifications alert did not appear")
|
||||||
systemAlert.scrollViews.otherElements.buttons["Allow"].tap()
|
let allowButton = systemAlert.scrollViews.otherElements.buttons["Allow"]
|
||||||
|
_ = allowButton.exists || allowButton.waitForExistence(timeout: 0.5)
|
||||||
|
allowButton.tap()
|
||||||
|
|
||||||
// Do the actual validation
|
// Do the actual validation
|
||||||
try performBulkAddingRecommendedSources(for: app)
|
try performBulkAddingRecommendedSources(for: app)
|
||||||
@@ -97,7 +99,9 @@ final class UITests: XCTestCase {
|
|||||||
|
|
||||||
// if it exists keep going immediately else wait for upto 5 sec with polling every 1 sec for existence
|
// if it exists keep going immediately else wait for upto 5 sec with polling every 1 sec for existence
|
||||||
XCTAssertTrue(systemAlert.exists || systemAlert.waitForExistence(timeout: 5), "Notifications alert did not appear")
|
XCTAssertTrue(systemAlert.exists || systemAlert.waitForExistence(timeout: 5), "Notifications alert did not appear")
|
||||||
systemAlert.scrollViews.otherElements.buttons["Allow"].tap()
|
let allowButton = systemAlert.scrollViews.otherElements.buttons["Allow"]
|
||||||
|
_ = allowButton.exists || allowButton.waitForExistence(timeout: 0.5)
|
||||||
|
allowButton.tap()
|
||||||
|
|
||||||
// Do the actual validation
|
// Do the actual validation
|
||||||
try performBulkAddingInputSources(for: app)
|
try performBulkAddingInputSources(for: app)
|
||||||
@@ -112,7 +116,9 @@ final class UITests: XCTestCase {
|
|||||||
|
|
||||||
// if it exists keep going immediately else wait for upto 5 sec with polling every 1 sec for existence
|
// if it exists keep going immediately else wait for upto 5 sec with polling every 1 sec for existence
|
||||||
XCTAssertTrue(systemAlert.exists || systemAlert.waitForExistence(timeout: 5), "Notifications alert did not appear")
|
XCTAssertTrue(systemAlert.exists || systemAlert.waitForExistence(timeout: 5), "Notifications alert did not appear")
|
||||||
systemAlert.scrollViews.otherElements.buttons["Allow"].tap()
|
let allowButton = systemAlert.scrollViews.otherElements.buttons["Allow"]
|
||||||
|
_ = allowButton.exists || allowButton.waitForExistence(timeout: 0.5)
|
||||||
|
allowButton.tap()
|
||||||
|
|
||||||
// Do the actual validation
|
// Do the actual validation
|
||||||
try performRepeatabilityForStagingInputSources(for: app)
|
try performRepeatabilityForStagingInputSources(for: app)
|
||||||
@@ -127,7 +133,9 @@ final class UITests: XCTestCase {
|
|||||||
|
|
||||||
// if it exists keep going immediately else wait for upto 5 sec with polling every 1 sec for existence
|
// if it exists keep going immediately else wait for upto 5 sec with polling every 1 sec for existence
|
||||||
XCTAssertTrue(systemAlert.exists || systemAlert.waitForExistence(timeout: 5), "Notifications alert did not appear")
|
XCTAssertTrue(systemAlert.exists || systemAlert.waitForExistence(timeout: 5), "Notifications alert did not appear")
|
||||||
systemAlert.scrollViews.otherElements.buttons["Allow"].tap()
|
let allowButton = systemAlert.scrollViews.otherElements.buttons["Allow"]
|
||||||
|
_ = allowButton.exists || allowButton.waitForExistence(timeout: 0.5)
|
||||||
|
allowButton.tap()
|
||||||
|
|
||||||
// Do the actual validation
|
// Do the actual validation
|
||||||
try performRepeatabilityForStagingRecommendedSources(for: app)
|
try performRepeatabilityForStagingRecommendedSources(for: app)
|
||||||
@@ -213,19 +221,19 @@ private extension UITests {
|
|||||||
let button = springboard_app.buttons["Remove App"]
|
let button = springboard_app.buttons["Remove App"]
|
||||||
_ = button.exists || button.waitForExistence(timeout: 5)
|
_ = button.exists || button.waitForExistence(timeout: 5)
|
||||||
button.tap()
|
button.tap()
|
||||||
_ = springboard_app.waitForExistence(timeout: 0.3)
|
_ = springboard_app.waitForExistence(timeout: 0.5)
|
||||||
}
|
}
|
||||||
do {
|
do {
|
||||||
let button = springboard_app.buttons["Delete App"]
|
let button = springboard_app.buttons["Delete App"]
|
||||||
_ = button.waitForExistence(timeout: 0.3)
|
_ = button.waitForExistence(timeout: 0.5)
|
||||||
button.tap()
|
button.tap()
|
||||||
_ = springboard_app.waitForExistence(timeout: 0.3)
|
_ = springboard_app.waitForExistence(timeout: 0.5)
|
||||||
}
|
}
|
||||||
do {
|
do {
|
||||||
let button = springboard_app.buttons["Delete"]
|
let button = springboard_app.buttons["Delete"]
|
||||||
_ = button.waitForExistence(timeout: 0.3)
|
_ = button.waitForExistence(timeout: 0.5)
|
||||||
button.tap()
|
button.tap()
|
||||||
_ = springboard_app.waitForExistence(timeout: 0.3)
|
_ = springboard_app.waitForExistence(timeout: 0.5)
|
||||||
}
|
}
|
||||||
|
|
||||||
// // Press home once to make the icons stop wiggling
|
// // Press home once to make the icons stop wiggling
|
||||||
@@ -275,19 +283,49 @@ private extension UITests {
|
|||||||
try tapAddForThesePickedSources(app: app, sourceMappings: sourceMappings, cellsQuery: cellsQuery)
|
try tapAddForThesePickedSources(app: app, sourceMappings: sourceMappings, cellsQuery: cellsQuery)
|
||||||
|
|
||||||
// Commit the changes by tapping "Done".
|
// Commit the changes by tapping "Done".
|
||||||
app.navigationBars["Add Source"].buttons["Done"].tap()
|
let doneButton = app.navigationBars["Add Source"].buttons["Done"]
|
||||||
|
_ = doneButton.waitForExistence(timeout: 0.5)
|
||||||
|
doneButton.tap()
|
||||||
|
|
||||||
// Accept each source addition via alert.
|
// Accept each source addition via alert.
|
||||||
for source in sourceMappings {
|
for source in sourceMappings {
|
||||||
let alertIdentifier = "Would you like to add the source “\(source.alertTitle)”?"
|
let alertIdentifier = "Would you like to add the source “\(source.alertTitle)”?"
|
||||||
let addSourceButton = app.alerts[alertIdentifier]
|
let addSourceButton = app.alerts[alertIdentifier]
|
||||||
.scrollViews.otherElements.buttons["Add Source"]
|
.scrollViews.otherElements.buttons["Add Source"]
|
||||||
_ = addSourceButton.exists || addSourceButton.waitForExistence(timeout: 0.3)
|
_ = addSourceButton.waitForExistence(timeout: 0.5)
|
||||||
addSourceButton.tap()
|
addSourceButton.tap()
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
private func performBulkAddingRecommendedSources(for app: XCUIApplication) throws {
|
||||||
|
// Navigate to the Sources screen and open the Add Source view.
|
||||||
|
let srcTab = app.tabBars["Tab Bar"].buttons["Sources"]
|
||||||
|
_ = srcTab.waitForExistence(timeout: 0.5)
|
||||||
|
srcTab.tap()
|
||||||
|
let srcAdd = app.navigationBars["Sources"].buttons["Add"]
|
||||||
|
_ = srcAdd.waitForExistence(timeout: 0.5)
|
||||||
|
srcAdd.tap()
|
||||||
|
|
||||||
|
let cellsQuery = app.collectionViews.cells
|
||||||
|
|
||||||
|
// Data model for recommended sources. NOTE: This list order is required to be the same as that of "Add Source" Screen
|
||||||
|
let recommendedSources: [(identifier: String, alertTitle: String, requiresSwipe: Bool)] = [
|
||||||
|
("SideStore Team Picks\ncommunity-apps.sidestore.io/sidecommunity.json", "SideStore Team Picks", false),
|
||||||
|
("Provenance EMU\nprovenance-emu.com/apps.json", "Provenance EMU", false),
|
||||||
|
("Countdown Respository\nneoarz.github.io/Countdown-App/Countdown.json", "Countdown Respository", false),
|
||||||
|
("OatmealDome's AltStore Source\naltstore.oatmealdome.me", "OatmealDome's AltStore Source", true),
|
||||||
|
("UTM Repository\nVirtual machines for iOS", "UTM Repository", false),
|
||||||
|
("Flyinghead\nflyinghead.github.io/flycast-builds/altstore.json", "Flyinghead", false),
|
||||||
|
// ("PojavLauncher Repository\nalt.crystall1ne.dev", "PojavLauncher Repository", false), // not a stable source, sometimes becomes unreachable, so disabled
|
||||||
|
("PokeMMO\npokemmo.eu/altstore/", "PokeMMO", true),
|
||||||
|
("Odyssey\ntheodyssey.dev/altstore/odysseysource.json", "Odyssey", false),
|
||||||
|
("Yattee\nrepos.yattee.stream/alt/apps.json", "Yattee", false),
|
||||||
|
("ThatStella7922 Source\nThe home for all apps ThatStella7922", "ThatStella7922 Source", false)
|
||||||
|
]
|
||||||
|
|
||||||
|
try performBulkAdd(app: app, sourceMappings: recommendedSources, cellsQuery: cellsQuery)
|
||||||
|
}
|
||||||
|
|
||||||
private func performBulkAddingInputSources(for app: XCUIApplication) throws {
|
private func performBulkAddingInputSources(for app: XCUIApplication) throws {
|
||||||
|
|
||||||
@@ -305,19 +343,22 @@ private extension UITests {
|
|||||||
https://bit.ly/Quantumsource
|
https://bit.ly/Quantumsource
|
||||||
""".trimmedIndentation
|
""".trimmedIndentation
|
||||||
|
|
||||||
let app = XCUIApplication()
|
let srcTab = app.tabBars["Tab Bar"].buttons["Sources"]
|
||||||
app.tabBars["Tab Bar"].buttons["Sources"].tap()
|
_ = srcTab.waitForExistence(timeout: 0.5)
|
||||||
app.navigationBars["Sources"].buttons["Add"].tap()
|
srcTab.tap()
|
||||||
_ = app.waitForExistence(timeout: 0.5)
|
let srcAdd = app.navigationBars["Sources"].buttons["Add"]
|
||||||
|
_ = srcAdd.waitForExistence(timeout: 0.5)
|
||||||
|
srcAdd.tap()
|
||||||
|
|
||||||
let collectionViewsQuery = app.collectionViews
|
let collectionViewsQuery = app.collectionViews
|
||||||
let appsSidestoreIoTextField = collectionViewsQuery.textFields["apps.sidestore.io"]
|
let appsSidestoreIoTextField = collectionViewsQuery.textFields["apps.sidestore.io"]
|
||||||
_ = appsSidestoreIoTextField.exists || appsSidestoreIoTextField.waitForExistence(timeout: 5)
|
_ = appsSidestoreIoTextField.waitForExistence(timeout: 0.5)
|
||||||
_ = app.waitForExistence(timeout: 0.5)
|
|
||||||
appsSidestoreIoTextField.tap()
|
appsSidestoreIoTextField.tap()
|
||||||
appsSidestoreIoTextField.tap()
|
appsSidestoreIoTextField.tap()
|
||||||
collectionViewsQuery.staticTexts["Paste"].tap()
|
_ = appsSidestoreIoTextField.waitForExistence(timeout: 0.5)
|
||||||
_ = app.waitForExistence(timeout: 0.5)
|
let pasteButton = collectionViewsQuery.staticTexts["Paste"]
|
||||||
|
_ = pasteButton.waitForExistence(timeout: 0.5)
|
||||||
|
pasteButton.tap()
|
||||||
|
|
||||||
// if app.keyboards.buttons["Return"].exists {
|
// if app.keyboards.buttons["Return"].exists {
|
||||||
// app.keyboards.buttons["Return"].tap()
|
// app.keyboards.buttons["Return"].tap()
|
||||||
@@ -330,7 +371,7 @@ private extension UITests {
|
|||||||
|
|
||||||
if app.keyboards.count > 0 {
|
if app.keyboards.count > 0 {
|
||||||
appsSidestoreIoTextField.typeText("\n") // Fallback to newline so that soft kb is dismissed
|
appsSidestoreIoTextField.typeText("\n") // Fallback to newline so that soft kb is dismissed
|
||||||
_ = app.waitForExistence(timeout: 0.5)
|
_ = app.exists || app.waitForExistence(timeout: 0.5)
|
||||||
}
|
}
|
||||||
|
|
||||||
let cellsQuery = collectionViewsQuery.cells
|
let cellsQuery = collectionViewsQuery.cells
|
||||||
@@ -351,6 +392,31 @@ private extension UITests {
|
|||||||
try performBulkAdd(app: app, sourceMappings: textInputSources, cellsQuery: cellsQuery)
|
try performBulkAdd(app: app, sourceMappings: textInputSources, cellsQuery: cellsQuery)
|
||||||
}
|
}
|
||||||
|
|
||||||
|
private func performRepeatabilityForStagingRecommendedSources(for app: XCUIApplication) throws {
|
||||||
|
// Navigate to the Sources screen and open the Add Source view.
|
||||||
|
let srcTab = app.tabBars["Tab Bar"].buttons["Sources"]
|
||||||
|
srcTab.tap()
|
||||||
|
_ = srcTab.waitForExistence(timeout: 0.5)
|
||||||
|
let srcAdd = app.navigationBars["Sources"].buttons["Add"]
|
||||||
|
srcAdd.tap()
|
||||||
|
_ = srcAdd.waitForExistence(timeout: 0.5)
|
||||||
|
|
||||||
|
let cellsQuery = app.collectionViews.cells
|
||||||
|
|
||||||
|
// Data model for recommended sources. NOTE: This list order is required to be the same as that of "Add Source" Screen
|
||||||
|
let recommendedSources: [(identifier: String, alertTitle: String, requiresSwipe: Bool)] = [
|
||||||
|
("SideStore Team Picks\ncommunity-apps.sidestore.io/sidecommunity.json", "SideStore Team Picks", false),
|
||||||
|
("Provenance EMU\nprovenance-emu.com/apps.json", "Provenance EMU", false),
|
||||||
|
("Countdown Respository\nneoarz.github.io/Countdown-App/Countdown.json", "Countdown Respository", false),
|
||||||
|
("OatmealDome's AltStore Source\naltstore.oatmealdome.me", "OatmealDome's AltStore Source", false),
|
||||||
|
("UTM Repository\nVirtual machines for iOS", "UTM Repository", false),
|
||||||
|
]
|
||||||
|
|
||||||
|
let repeatCount = 3 // number of times to run the entire sequence
|
||||||
|
let timeSeed = UInt64(Date().timeIntervalSince1970) // time is unique (upto microseconds) - uncomment this to use non-deterministic seed based RNG (random number generator)
|
||||||
|
|
||||||
|
try repeatabilityTest(app: app, sourceMappings: recommendedSources, cellsQuery: cellsQuery, repeatCount: repeatCount, seed: timeSeed)
|
||||||
|
}
|
||||||
|
|
||||||
private func performRepeatabilityForStagingInputSources(for app: XCUIApplication) throws {
|
private func performRepeatabilityForStagingInputSources(for app: XCUIApplication) throws {
|
||||||
|
|
||||||
@@ -364,25 +430,28 @@ private extension UITests {
|
|||||||
https://bit.ly/40Isul6
|
https://bit.ly/40Isul6
|
||||||
""".trimmedIndentation
|
""".trimmedIndentation
|
||||||
|
|
||||||
let app = XCUIApplication()
|
let srcTab = app.tabBars["Tab Bar"].buttons["Sources"]
|
||||||
app.tabBars["Tab Bar"].buttons["Sources"].tap()
|
_ = srcTab.waitForExistence(timeout: 0.5)
|
||||||
app.navigationBars["Sources"].buttons["Add"].tap()
|
srcTab.tap()
|
||||||
_ = app.waitForExistence(timeout: 0.5)
|
let srcAdd = app.navigationBars["Sources"].buttons["Add"]
|
||||||
|
_ = srcAdd.waitForExistence(timeout: 0.5)
|
||||||
|
srcAdd.tap()
|
||||||
|
|
||||||
|
|
||||||
let collectionViewsQuery = app.collectionViews
|
let collectionViewsQuery = app.collectionViews
|
||||||
let appsSidestoreIoTextField = collectionViewsQuery.textFields["apps.sidestore.io"]
|
let appsSidestoreIoTextField = collectionViewsQuery.textFields["apps.sidestore.io"]
|
||||||
_ = appsSidestoreIoTextField.exists || appsSidestoreIoTextField.waitForExistence(timeout: 5)
|
_ = appsSidestoreIoTextField.waitForExistence(timeout: 0.5)
|
||||||
_ = app.waitForExistence(timeout: 0.5)
|
|
||||||
appsSidestoreIoTextField.tap()
|
appsSidestoreIoTextField.tap()
|
||||||
appsSidestoreIoTextField.tap()
|
appsSidestoreIoTextField.tap()
|
||||||
_ = appsSidestoreIoTextField.exists || appsSidestoreIoTextField.waitForExistence(timeout: 5)
|
_ = appsSidestoreIoTextField.waitForExistence(timeout: 0.5)
|
||||||
collectionViewsQuery.staticTexts["Paste"].tap()
|
let pasteButton = collectionViewsQuery.staticTexts["Paste"]
|
||||||
_ = app.waitForExistence(timeout: 0.5)
|
_ = pasteButton.waitForExistence(timeout: 0.5)
|
||||||
|
pasteButton.tap()
|
||||||
|
|
||||||
|
|
||||||
if app.keyboards.count > 0 {
|
if app.keyboards.count > 0 {
|
||||||
appsSidestoreIoTextField.typeText("\n") // Fallback to newline so that soft kb is dismissed
|
appsSidestoreIoTextField.typeText("\n") // Fallback to newline so that soft kb is dismissed
|
||||||
_ = app.waitForExistence(timeout: 0.5)
|
_ = app.exists || app.waitForExistence(timeout: 0.5)
|
||||||
}
|
}
|
||||||
|
|
||||||
let cellsQuery = collectionViewsQuery.cells
|
let cellsQuery = collectionViewsQuery.cells
|
||||||
@@ -435,11 +504,11 @@ private extension UITests {
|
|||||||
.children(matching: .button)[source.identifier]
|
.children(matching: .button)[source.identifier]
|
||||||
XCTAssert(sourceButton.exists || sourceButton.waitForExistence(timeout: 10), "Source preview for id: '\(source.alertTitle)' not found in the view")
|
XCTAssert(sourceButton.exists || sourceButton.waitForExistence(timeout: 10), "Source preview for id: '\(source.alertTitle)' not found in the view")
|
||||||
|
|
||||||
_ = sourceButton.waitForExistence(timeout: 0.5)
|
_ = sourceButton.exists || sourceButton.waitForExistence(timeout: 0.5)
|
||||||
|
|
||||||
// let addButton = sourceButton.children(matching: .button).firstMatch
|
// let addButton = sourceButton.children(matching: .button).firstMatch
|
||||||
// let addButton = sourceButton.descendants(matching: .button)["add"]
|
// let addButton = sourceButton.descendants(matching: .button)["add"]
|
||||||
// XCTAssert(addButton.exists || addButton.waitForExistence(timeout: 0.3), " `+` button for id: '\(source.alertTitle)' not found in the preview container")
|
// XCTAssert(addButton.exists || addButton.waitForExistence(timeout: 0.5), " `+` button for id: '\(source.alertTitle)' not found in the preview container")
|
||||||
// addButton.tap()
|
// addButton.tap()
|
||||||
|
|
||||||
let addButton = sourceButton.children(matching: .button)["add"]
|
let addButton = sourceButton.children(matching: .button)["add"]
|
||||||
@@ -451,59 +520,10 @@ private extension UITests {
|
|||||||
|
|
||||||
if source.requiresSwipe {
|
if source.requiresSwipe {
|
||||||
sourceButton.swipeUp(velocity: .slow) // Swipe up if needed.
|
sourceButton.swipeUp(velocity: .slow) // Swipe up if needed.
|
||||||
_ = sourceButton.waitForExistence(timeout: 0.1)
|
_ = sourceButton.waitForExistence(timeout: 0.5)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
private func performBulkAddingRecommendedSources(for app: XCUIApplication) throws {
|
|
||||||
// Navigate to the Sources screen and open the Add Source view.
|
|
||||||
app.tabBars["Tab Bar"].buttons["Sources"].tap()
|
|
||||||
app.navigationBars["Sources"].buttons["Add"].tap()
|
|
||||||
_ = app.waitForExistence(timeout: 0.5)
|
|
||||||
|
|
||||||
let cellsQuery = app.collectionViews.cells
|
|
||||||
|
|
||||||
// Data model for recommended sources. NOTE: This list order is required to be the same as that of "Add Source" Screen
|
|
||||||
let recommendedSources: [(identifier: String, alertTitle: String, requiresSwipe: Bool)] = [
|
|
||||||
("SideStore Team Picks\ncommunity-apps.sidestore.io/sidecommunity.json", "SideStore Team Picks", false),
|
|
||||||
("Provenance EMU\nprovenance-emu.com/apps.json", "Provenance EMU", false),
|
|
||||||
("Countdown Respository\nneoarz.github.io/Countdown-App/Countdown.json", "Countdown Respository", false),
|
|
||||||
("OatmealDome's AltStore Source\naltstore.oatmealdome.me", "OatmealDome's AltStore Source", true),
|
|
||||||
("UTM Repository\nVirtual machines for iOS", "UTM Repository", false),
|
|
||||||
("Flyinghead\nflyinghead.github.io/flycast-builds/altstore.json", "Flyinghead", false),
|
|
||||||
// ("PojavLauncher Repository\nalt.crystall1ne.dev", "PojavLauncher Repository", false), // not a stable source, sometimes becomes unreachable, so disabled
|
|
||||||
("PokeMMO\npokemmo.eu/altstore/", "PokeMMO", true),
|
|
||||||
("Odyssey\ntheodyssey.dev/altstore/odysseysource.json", "Odyssey", false),
|
|
||||||
("Yattee\nrepos.yattee.stream/alt/apps.json", "Yattee", false),
|
|
||||||
("ThatStella7922 Source\nThe home for all apps ThatStella7922", "ThatStella7922 Source", false)
|
|
||||||
]
|
|
||||||
|
|
||||||
try performBulkAdd(app: app, sourceMappings: recommendedSources, cellsQuery: cellsQuery)
|
|
||||||
}
|
|
||||||
|
|
||||||
private func performRepeatabilityForStagingRecommendedSources(for app: XCUIApplication) throws {
|
|
||||||
// Navigate to the Sources screen and open the Add Source view.
|
|
||||||
app.tabBars["Tab Bar"].buttons["Sources"].tap()
|
|
||||||
app.navigationBars["Sources"].buttons["Add"].tap()
|
|
||||||
_ = app.waitForExistence(timeout: 0.5)
|
|
||||||
|
|
||||||
let cellsQuery = app.collectionViews.cells
|
|
||||||
|
|
||||||
// Data model for recommended sources. NOTE: This list order is required to be the same as that of "Add Source" Screen
|
|
||||||
let recommendedSources: [(identifier: String, alertTitle: String, requiresSwipe: Bool)] = [
|
|
||||||
("SideStore Team Picks\ncommunity-apps.sidestore.io/sidecommunity.json", "SideStore Team Picks", false),
|
|
||||||
("Provenance EMU\nprovenance-emu.com/apps.json", "Provenance EMU", false),
|
|
||||||
("Countdown Respository\nneoarz.github.io/Countdown-App/Countdown.json", "Countdown Respository", false),
|
|
||||||
("OatmealDome's AltStore Source\naltstore.oatmealdome.me", "OatmealDome's AltStore Source", false),
|
|
||||||
("UTM Repository\nVirtual machines for iOS", "UTM Repository", false),
|
|
||||||
]
|
|
||||||
|
|
||||||
let repeatCount = 3 // number of times to run the entire sequence
|
|
||||||
let timeSeed = UInt64(Date().timeIntervalSince1970) // time is unique (upto microseconds) - uncomment this to use non-deterministic seed based RNG (random number generator)
|
|
||||||
|
|
||||||
try repeatabilityTest(app: app, sourceMappings: recommendedSources, cellsQuery: cellsQuery, repeatCount: repeatCount, seed: timeSeed)
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user