Commit 33f33afe31
Verified · cmc
Layout: unified · split
gitbayUITests/LiveSmokeUITests.swift +10 −2
| @@ -87,8 +87,11 @@ final class LiveSmokeUITests: XCTestCase { | ||
| 87 | 87 | closeSmokeMergeRequests() |
| 88 | 88 | _ = runCommand(["mr", "create", Self.fixtureRepo, "--source", "ui-smoke", "--target", "main", |
| 89 | 89 | "--title", Self.labelledTitle]) |
| 90 | try XCTSkipUnless(openSmokeMergeRequests().map { $0.title }.contains(Self.labelledTitle), | |
| 91 | "could not open the label fixture merge request on \(Self.fixtureRepo)") | |
| 90 | _ = runCommand(["mr", "create", Self.fixtureRepo, "--source", "main", "--target", "ui-smoke", | |
| 91 | "--title", Self.unlabelledTitle]) | |
| 92 | let open = openSmokeMergeRequests().map { $0.title } | |
| 93 | try XCTSkipUnless(open.contains(Self.labelledTitle) && open.contains(Self.unlabelledTitle), | |
| 94 | "could not open both label fixture merge requests on \(Self.fixtureRepo)") | |
| 92 | 95 | } |
| 93 | 96 | } |
| 94 | 97 | |
| @@ -152,6 +155,7 @@ final class LiveSmokeUITests: XCTestCase { | ||
| 152 | 155 | static let supersededTitle = "UI smoke: superseded" |
| 153 | 156 | static let successorTitle = "UI smoke: successor" |
| 154 | 157 | static let labelledTitle = "UI smoke: labels" |
| 158 | static let unlabelledTitle = "UI smoke: unlabelled" | |
| 155 | 159 | static let smokeMRLabel = "ui-smoke-mr-label" |
| 156 | 160 | |
| 157 | 161 | /// Close in favour needs two open merge requests. The fixture branch |
| @@ -1869,6 +1873,8 @@ extension LiveSmokeUITests { | ||
| 1869 | 1873 | XCTAssertTrue(remove.waitForExistence(timeout: 15), "added label has no chip") |
| 1870 | 1874 | |
| 1871 | 1875 | back() |
| 1876 | XCTAssertTrue(app.staticTexts[Self.unlabelledTitle].firstMatch.waitForExistence(timeout: 15), | |
| 1877 | "unlabelled fixture MR not listed") | |
| 1872 | 1878 | app.descendants(matching: .any).matching(identifier: "mr-filter-button").firstMatch.tap() |
| 1873 | 1879 | let menu = app.descendants(matching: .any).matching(identifier: "filter-label-menu").firstMatch |
| 1874 | 1880 | XCTAssertTrue(menu.waitForExistence(timeout: 10), "MR filter sheet has no label picker") |
| @@ -1878,6 +1884,8 @@ extension LiveSmokeUITests { | ||
| 1878 | 1884 | choice.tap() |
| 1879 | 1885 | app.buttons["Done"].firstMatch.tap() |
| 1880 | 1886 | XCTAssertTrue(row.waitForExistence(timeout: 15), "label filter dropped the labelled MR") |
| 1887 | XCTAssertTrue(app.staticTexts[Self.unlabelledTitle].firstMatch.waitForNonExistence(timeout: 15), | |
| 1888 | "label filter did not narrow the list") | |
| 1881 | 1889 | |
| 1882 | 1890 | row.tap() |
| 1883 | 1891 | XCTAssertTrue(scrollTo(remove), "chip missing on reopen") |