From 17c428aebfa88bb6ac9e46141dba7230c58e6ec5 Mon Sep 17 00:00:00 2001 From: Martin Brennan Date: Fri, 3 May 2024 09:31:16 +1000 Subject: [PATCH] DEV: Add confirm_danger to Dialog page object (#26846) Some dialogs are dangerous...we need to accommodate that too. --- spec/system/page_objects/components/dialog.rb | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/spec/system/page_objects/components/dialog.rb b/spec/system/page_objects/components/dialog.rb index bc11ddf886e..f22e9f1cecd 100644 --- a/spec/system/page_objects/components/dialog.rb +++ b/spec/system/page_objects/components/dialog.rb @@ -19,6 +19,10 @@ module PageObjects find(".dialog-footer .btn-primary").click end + def click_danger + find(".dialog-footer .btn-danger").click + end + alias click_ok click_yes def click_no