Questions tagged [geb]

Geb is a library for headless web browsing on the JVM, suitable for automation and functional web testing. It uses Groovy to provide a concise story-like DSL for defining steps, and a concise and manageable DSL for defining page structure using the page object pattern.

Geb is a library for headless web browsing on the JVM, suitable for automation and functional web testing. It utilises the dynamic language features of Groovy to provide a concise story-like DSL for defining steps, and a concise and manageable DSL for defining page structure using the page object pattern.

Geb is based on the automation framework WebDriver and it can be used for scripting, scraping and general automation — or equally as a functional/web/acceptance testing solution via integration with testing frameworks such as Spock, JUnit, Selenium & TestNG.

822 questions
0
votes
1 answer

How to press 'y' in popup cofirmation window by GEB?

I'm trying to automate file download function. When I click a link of PDF, download confirmation window will pop up. How to write geb code to click Y in (Y/N) selection in popup window by GEB script?
user1534379
  • 1
  • 1
  • 3
0
votes
3 answers

CSS selector help for below structure

I have to find the anchor "a" nested under table with class as table.ic-table-creditReportProduct table tr. I tried but doesn't seem to work. Any ideas where the problem might be or another way to reference it. NOTE: I can't use the id's that have…
Aravind Yarram
  • 78,777
  • 46
  • 231
  • 327
0
votes
1 answer

"to SearchPage" call from the "then" block

Why is the below Geb test failing with the below error. Can't I call to SearchPage in the then block? Condition not satisfied: to SearchPage | null at test.LogoutSpec.Verify that the logout takes the user to login…
Aravind Yarram
  • 78,777
  • 46
  • 231
  • 327
-1
votes
1 answer

Starting out with Geb

I haven't coded in such a long time and now i'm going headfirst into Geb w/o knowing Groovy, jQuery syntax and generally being very rusty and so i expect to be asking a few questions starting with setup. I have installed the following - JDK,…
hnaderi
  • 409
  • 8
  • 16
-1
votes
1 answer

How to write xpath in groovy for table dom

How to write XPath for above table 2nd row in Groovy (Geb and Spock framework)?
-1
votes
1 answer

WebDriverManager: Impossible to pull image selenoid/vnc from inside docker

I have a Geb and Spock Maven project using WebDriverManager (using version 5.0.4-SNAPSHOT and selenium 3.141.159). I was successfully able to run tests using browser in docker option from my local Maven but it failed when trying to run inside a…
-1
votes
1 answer

Sample project to automate Mobile app using geb with appium

I am trying to automate mobile app using Geb with appium. Just want to know how to use it through page objects. I set the capabilities but I am confused at getBrowser(). Do we have to use getBrowser() since its an native app. Any help would be…
-1
votes
1 answer

Groovy File uploading and execute

I want to upload the file in the Query tool page from my application . I saved all the SQL scripts in my project's folder i need to upload those scripts 1 by 1 and execute it. For my automation test script And the file uploading is dependent. please…
Ashwin
  • 1
  • 1
-1
votes
1 answer

Geb Page objects methods not accessible in cucumber steps implementation

I am able to read the text of an element on a web page through my cucumber steps file but when I want to move that method to Page Object file then system throws an error. The framework used: Groovy, Geb, Cucumber, Gradle Steps…
Varun Jain
  • 11
  • 4
-1
votes
1 answer

Spock blocks - Best Practices

Trying to implement some best pratices to the spock blocks in the project and was wondering if there is anything else to follow other than using action calls in when/and block and assertions in then. Any documentation that I can look at? Please…
S.N
  • 1
-1
votes
2 answers

Send text to Text Field

How to send Text in text area field using geb & Spock? Using just Selenium & the sendKeys I am able to send the text. But unable to implement using geb spock. this[field] = value - Not working element.sendKeys(""); - Working
Sandip Das
  • 35
  • 9
-1
votes
1 answer

Showing error isDisplayed() and .text() navigator error after upgrading Geb to 1.0 from 0.10.0 and selenium to 3.0.1

I was trying to upgrade Geb and Selenium version in build.gradle. After updating version geb 0.10.0 to geb 1.0 and Selenium 2.47.1 to 3.0.1 giving error as .isDisplayed and text() methods navigator error. I am using groovy 2.4.3. I am using…
-1
votes
1 answer

NoSuchWindowException when trying to get a report inside a new window

I have the following in my code: withWindow({ title == 'Google' }) { report "08" } And report is leading me to the exception NoSuchWindowException. I've checked if that was a problem of the Window selector and it isn't,After some research I…
Pablo
  • 534
  • 11
  • 31
-1
votes
2 answers

How can I search and return the values and pass it to the method from spock table

Currently implementing GEB,Spock,Groovy. I come across the scenario like There is a set of data's in the spock table. I have to pass the modulename as a parameter, Search from the spock table then return two values user id and password. Below code…
-1
votes
1 answer

Spock: if-else check in spock - Check element visibbility

I need to click login button if logout button is not displayed and logout button if login button is not displayed. How I can check this in when,then blocks in Spock? I mean how if-else is supported in Spock? In the Page, I have the content like…
Mahbub Rahman
  • 1,295
  • 1
  • 24
  • 44
1 2 3
54
55