yek
yek

Reputation: 127

Karate UI - Interaction with already opened browser

We are trying to test a POS(Point of sale) web application run on chromium(hosted in docker container). Chromium is run in kiosk mode so you would not see address bar, menu bar etc. Now the tricky part for us is to interact with this web application which is already open and running. I am just wondering which route or method of karate-ui should I use in this case so that I don't end up opening a fresh browser session.

Upvotes: 1

Views: 875

Answers (1)

Peter Thomas
Peter Thomas

Reputation: 58088

It is important to have Chrome start with the debug-port enabled: --remote-debugging-port - so if you can get the POS team to make this change, you are in business. It should be easy actually

a) pass an enviroment variable so the POS docker container adds that CLI arg to chrome

b) allow that port for the Docker container

You may get some ideas from the Karate Docker container: https://github.com/intuit/karate/blob/master/karate-docker/karate-chrome/supervisord.conf

Then use the Karate UI driver config as start: false, port: <port you set, typically 9222>

Upvotes: 1

Related Questions