openfin / hello-openfin-selenium-java-example

Example of Java test code with Chrome Driver on OpenFin Runtime
MIT License
5 stars 5 forks source link

can't sendkeys in login UI #8

Open loisalex opened 2 years ago

loisalex commented 2 years ago

Dear openfin experts,

I faced a issue below, hope your resolution, thanks.

issue description: when navigate to my login page(window) after get driver successfully, i can find element(username), but sendkeys('124') not works. there is no error, it seems windhandle can't control my UI element(login UI)

code: selenium.WebDriver driver driver.navigate().to("http://****:8087/login.html"); Actions actions = new Actions(driver); WebElement login=driver.findElement(By.id("username")); login.sendKeys(Keys.CONTROL,Keys.chord("a")); login.sendKeys(Keys.BACK_SPACE); actions.moveToElement(driver.findElement(By.id("username"))).sendKeys("124").perform()

my application window information: { "uuid": "app_shell", "name": "app_shell", "url": "http://**:8087/provider.html", "parentName": "app_shell", "parentUUID": "app_shell", "childCount": 1, "windowInfo": { "size": "533w333h", "position": "(7,7)", "monitor": "" }, "showing": false, "subRows": [ { "uuid": "fmo_app_shell", "name": "internal-generated-window-d7fc4026-396d-4f73-88e7-4b278c41afd5", "url": "http://***:8087/login.html", "parentName": "app_shell", "parentUUID": "app_shell", "childCount": 1, "windowInfo": { "size": "400w374h", "position": "(153,440)", "monitor": "" }, "showing": true } ] }

loisalex commented 2 years ago

when start app there is a background service that only can be controlled by chrome driver notification service: https://cdn.openfin.co/release/system-apps/notification-center/1.11.0/provider.html https://cdn.openfin.co/release/system-apps/notification-center/1.11.0/toast.html https://cdn.openfin.co/release/system-apps/notification-center/1.11.0

loisalex commented 2 years ago

does only debug mode app support selenium?