Reputation: 31
I'm trying to do a basic UI automation in my existing BDD karate project which is working perfectly fine for API and UI automation test.same UI test which worked previously has stopped working due to this error. But when I try to open any website with karate ui test it throws a Java.lang.AssertionError: org.apache..http.client.utils.URIBuilder.getPathSegments()Ljava/util/List
Currently I'm using karate 1.2.1.RC2 version and I tried updating it to the latest version 1.3.0 but that also didn't worked
Background:
* config driver = { type:'chrome', executable: 'chrome' , showDriverLog: true, executable: 'C://Program Files//Google//Chrome//Application//chrome.exe'
@test
Scenario: to run ui automation
Given driver 'https://www.google.com'
Upvotes: 0
Views: 541
Reputation: 61
I had this issue for API tests - it occurred on the "path" keyword for karate when you want to define path params. Turned out to be a conflict with the org.apache.httpcomponent:httpclient library. My project had version 4.5.6 which doesn't contain getPathSegments() method so solution was to upgrade that library to version 4.5.13 and it fixed the issue. I guess Karate must use this library underneath.
Upvotes: 0
Reputation: 131
The driver configuration was all over the place. A typical syntax is
* configure driver = {type:'chrome' , executable: <path to web driver executable>, showDriverLog: true}
Upvotes: 1