diff --git a/tests/e2e-playwright/pages/admin/courses/index.ts b/tests/e2e-playwright/pages/admin/courses/index.ts index 3dc42b10eb..bf0221ef03 100644 --- a/tests/e2e-playwright/pages/admin/courses/index.ts +++ b/tests/e2e-playwright/pages/admin/courses/index.ts @@ -92,7 +92,7 @@ export default class CoursesPage extends PostType { this.wizardModal = new WizardModal( wizardLocator ); this.createCourseButton = page.locator( - 'a.page-title-action[href$="post-new.php?post_type=course"]:has-text("New Course")' + 'a.page-title-action[href$="post-new.php?post_type=course"]:has-text("New Course"):visible' ); this.courseOutlineBlock = new CourseOutline( page );