Skip to content

Commit f120dba

Browse files
authored
Change fisrtCalendarDay locator from staticText to button (#21402)
1 parent 605427c commit f120dba

File tree

1 file changed

+4
-4
lines changed

1 file changed

+4
-4
lines changed

WordPress/UITestsFoundation/Screens/Editor/EditorPostSettings.swift

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -35,8 +35,8 @@ public class EditorPostSettings: ScreenObject {
3535
$0.buttons["Next Month"]
3636
}
3737

38-
private let firstCalendarDayLabelGetter: (XCUIApplication) -> XCUIElement = {
39-
$0.staticTexts["1"]
38+
private let firstCalendarDayButtonGetter: (XCUIApplication) -> XCUIElement = {
39+
$0.buttons.containing(.staticText, identifier: "1").element
4040
}
4141

4242
private let doneButtonGetter: (XCUIApplication) -> XCUIElement = {
@@ -48,7 +48,7 @@ public class EditorPostSettings: ScreenObject {
4848
var dateSelector: XCUIElement { dateSelectorGetter(app) }
4949
var doneButton: XCUIElement { doneButtonGetter(app) }
5050
var featuredImageButton: XCUIElement { featuredImageButtonGetter(app) }
51-
var firstCalendarDayLabel: XCUIElement { firstCalendarDayLabelGetter(app) }
51+
var firstCalendarDayButton: XCUIElement { firstCalendarDayButtonGetter(app) }
5252
var nextMonthButton: XCUIElement { nextMonthButtonGetter(app) }
5353
var publishDateButton: XCUIElement { publishDateButtonGetter(app) }
5454
var settingsTable: XCUIElement { settingsTableGetter(app) }
@@ -137,7 +137,7 @@ public class EditorPostSettings: ScreenObject {
137137

138138
// Selects the first day of the next month
139139
nextMonthButton.tap()
140-
firstCalendarDayLabel.tap()
140+
firstCalendarDayButton.tap()
141141

142142
doneButton.tap()
143143
return self

0 commit comments

Comments
 (0)