Skip to content

Commit 50ef4a7

Browse files
committed
Addressed PR comments and fixed some isues that prevented the C5 test from running
1 parent 57a22cd commit 50ef4a7

File tree

4 files changed

+6
-8
lines changed

4 files changed

+6
-8
lines changed

pages/datasets/colonoscopy_dataset_page.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -43,7 +43,7 @@ def select_asa_grade_option(self, option: str) -> None:
4343
Returns:
4444
None
4545
"""
46-
self.select_asa_grade_dropdowen.select_option(option)
46+
self.select_asa_grade_dropdown.select_option(option)
4747

4848
def select_fit_for_colonoscopy_option(self, option: str) -> None:
4949
"""

pages/datasets/subject_datasets_page.py

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -11,9 +11,7 @@ def __init__(self, page: Page):
1111
super().__init__(page)
1212
self.page = page
1313
# Subject datasets page locators
14-
self.colonoscopy_show_dataset_button = self.page.locator(
15-
"body > table > tbody > tr > td > div:nth-child(13) > div.DatasetLink > p > a"
16-
) # Using a more specific selector because we will have multiple buttons on the page with the same role and name
14+
self.colonoscopy_show_dataset_button = self.page.get_by_role(role="link", name="Show Dataset")
1715

1816
def click_colonoscopy_show_datasets(self) -> None:
1917
self.click(self.colonoscopy_show_dataset_button)

pages/screening_practitioner_appointments/appointment_detail_page.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@ def __init__(self, page: Page):
1010
self.attendance_radio = self.page.get_by_role("radio", name="Attendance")
1111
self.attendented_check_box = self.page.locator("#UI_ATTENDED")
1212
self.calendar_button = self.page.get_by_role("button", name="Calendar")
13-
self.save_button = self.page.get_by_role("button", name="Save").click()
13+
self.save_button = self.page.get_by_role("button", name="Save")
1414

1515
def check_attendance_radio(self) -> None:
1616
self.attendance_radio.check()

tests/smokescreen/test_compartment_5.py

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -76,11 +76,11 @@ def test_compartment_5(page: Page, smokescreen_properties: dict) -> None:
7676

7777
AppointmentCalendar(page).click_view_appointments_on_this_day_button()
7878
ScreeningPractitionerDayView(page).click_calendar_button()
79-
date_from_util = datetime(2025, 5, 1)
79+
date_from_util = datetime(2025, 4, 30)
8080
CalendarPicker(page).v1_calender_picker(date_from_util)
8181

8282
# Select subject from inital test data util
83-
ScreeningPractitionerDayView(page).click_patient_link("CRUMBLE REFUSE")
83+
ScreeningPractitionerDayView(page).click_patient_link("HELPER BACKBONED")
8484

8585
# Select Attendance radio button, tick Attended checkbox, set Attended Date to yesterday's (system) date and then press Save
8686
AppointmentDetail(page).check_attendance_radio()
@@ -93,7 +93,7 @@ def test_compartment_5(page: Page, smokescreen_properties: dict) -> None:
9393
# Repeat for x Abnormal patients
9494

9595
# Navigate to the 'Subject Screening Summary' screen for the 1st Abnormal patient
96-
nhs_no = "9724560430" # Test NHS NO for CRUMBLE REFUSE
96+
nhs_no = "9840589105" # Test NHS NO for CRUMBLE REFUSE
9797
verify_subject_event_status_by_nhs_no(
9898
page, nhs_no, "J10 - Attended Colonoscopy Assessment Appointment"
9999
)

0 commit comments

Comments
 (0)