From 31c325efdcd5379cf136dc5f4c5cf201855eb950 Mon Sep 17 00:00:00 2001 From: Markus Schulte Date: Mon, 29 Jan 2024 13:18:29 +0100 Subject: [PATCH] chore: Update selector for Wikipedia search button This commit changes the selector for the search button on the Wikipedia page. An adjustment was made to directly select the child button in the search form, improving selection accuracy and preventing potential errors. --- .../dev/schulte/spockgebdemo/wikipedia/WikipediaPage.groovy | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/test/groovy/dev/schulte/spockgebdemo/wikipedia/WikipediaPage.groovy b/src/test/groovy/dev/schulte/spockgebdemo/wikipedia/WikipediaPage.groovy index 58aa0a6..83396d6 100644 --- a/src/test/groovy/dev/schulte/spockgebdemo/wikipedia/WikipediaPage.groovy +++ b/src/test/groovy/dev/schulte/spockgebdemo/wikipedia/WikipediaPage.groovy @@ -12,9 +12,9 @@ class WikipediaPage extends Page { static content = { searchField { $("#searchInput") } - searchButton(to: WikipediaResultsPage) { $("#searchform button") } + searchButton(to: WikipediaResultsPage) { $("#searchform > button") } } - + void search(String searchTerm) { searchField.value searchTerm searchButton.click()