From 81ede0500561f7e1e6d0da8d2c49726b7c72a386 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?S=C3=A9rgio=20Saquetim?= <1108771+megothss@users.noreply.github.com> Date: Tue, 5 Mar 2024 20:04:05 -0300 Subject: [PATCH] DEV: Added `has_option_value` test to SelectKit system spec component (#26041) --- spec/system/page_objects/components/select_kit.rb | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/spec/system/page_objects/components/select_kit.rb b/spec/system/page_objects/components/select_kit.rb index 80c7a2793be..65ad55affc2 100644 --- a/spec/system/page_objects/components/select_kit.rb +++ b/spec/system/page_objects/components/select_kit.rb @@ -58,6 +58,10 @@ module PageObjects component.find(".select-kit-collection li[data-name='#{name}']") end + def has_option_value?(value) + component.find(".select-kit-collection li[data-value='#{value}']") + end + def expand collapsed_component.find(":not(.is-expanded) .select-kit-header", visible: :all).click expanded_component