mirror of
https://gitlab.opencode.de/bwi/bundesmessenger/clients/bundesmessenger-ios.git
synced 2026-04-21 17:12:45 +02:00
vector-im/element-ios/issues/5298 - Added build setting + ui and unit tests.
This commit is contained in:
committed by
Stefan Ceriu
parent
5f6b6b27aa
commit
0bac754ad9
@@ -24,13 +24,30 @@ class LocationSharingUITests: XCTestCase {
|
||||
|
||||
override func setUp() {
|
||||
continueAfterFailure = false
|
||||
|
||||
|
||||
app = XCUIApplication()
|
||||
app.launch()
|
||||
app.buttons[MockLocationSharingScreenState.screenStateKeys.first!].tap()
|
||||
}
|
||||
|
||||
func testInitialStateComponents() {
|
||||
func testInitialUserLocation() {
|
||||
goToScreenWithIdentifier(MockLocationSharingScreenState.shareUserLocation.title)
|
||||
|
||||
XCTAssertTrue(app.buttons["Cancel"].exists)
|
||||
XCTAssertTrue(app.buttons["Share"].exists)
|
||||
XCTAssertTrue(app.otherElements["Map"].exists)
|
||||
}
|
||||
|
||||
func testInitialExistingLocation() {
|
||||
goToScreenWithIdentifier(MockLocationSharingScreenState.displayExistingLocation.title)
|
||||
|
||||
XCTAssertTrue(app.buttons["Cancel"].exists)
|
||||
XCTAssertTrue(app.buttons["location share icon"].exists)
|
||||
XCTAssertTrue(app.otherElements["Map"].exists)
|
||||
}
|
||||
|
||||
// Need a delay when showing the map otherwise the simulator breaks
|
||||
private func goToScreenWithIdentifier(_ identifier: String) {
|
||||
app.goToScreenWithIdentifier(identifier)
|
||||
sleep(2)
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user