Skip to content

Commit 566a38e

Browse files
committed
Update UI Testing docs
1 parent 553bb85 commit 566a38e

File tree

1 file changed

+5
-3
lines changed

1 file changed

+5
-3
lines changed

CodeEditUITests/UI TESTING.md

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -21,12 +21,14 @@ without having to read long XCUI queries. For instance
2121
```swift
2222
let window = application.windows.element(matching: .window, identifier: "workspace")
2323
let navigator = window.descendants(matching: .any).matching(identifier: "ProjectNavigator").element
24-
let newFileCell = navigator.descendants(matching: .outlineRow)
24+
let newFileCell = navigator
25+
.descendants(matching: .outlineRow)
2526
.containing(.textField, identifier: "ProjectNavigatorTableViewCell-FileName")
26-
.element(boundBy: index)
27+
.element(boundBy: 0)
2728
```
2829

29-
Should be shortened to the following, which is much easier to read and intuit what the test is doing.
30+
Should be shortened to the following, which should be easier to read and intuit what the test is doing.
31+
3032
```swift
3133
let window = Query.getWindow(app)
3234
let navigator = Query.Window.getProjectNavigator(window)

0 commit comments

Comments
 (0)