aerokube / moon

Browser automation solution for Kubernetes and Openshift supporting Selenium, Playwright, Puppeteer and Cypress

Home Page:http://aerokube.com/moon/latest

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Not able to download the file in Moon browser

vidushi283 opened this issue · comments

We need to download the file from ui as part of test .
When button is clicked , instead of downloading the file It opens a dialog box/popup as below
image

ChromeOptions are set as below ( using Selenium+C#)

ChromeOptions.AddUserProfilePreference("download.default_directory", "/home/selenium/Downloads");

Have tried setting the default directory as below as well after reading the moon docs.
ChromeOptions.AddUserProfilePreference("download.default_directory", "/home/user/Downloads");

But nothing worked for us .

@vidushi283 did you try prefs from this answers? https://stackoverflow.com/questions/46937319/how-to-use-chrome-webdriver-in-selenium-to-download-files-in-python

@vania-pooh
Currently I have set
ChromeOptions.AddUserProfilePreference("download.default_directory", "/home/selenium/Downloads");
ChromeOptions.AddUserProfilePreference("download.prompt_for_download": False,);

with same pref , file is downloaded on moon instance on windows but gives the prompt when test is running on moon instance on AWS EKS

@vidushi283 are browser versions the same in both cases?

@vania-pooh Working fine . it seems middle ware was the culprit. I am using testkube as my test execution tool and it pulls the image of my code from ECR repository . It seems it was not pulling the latest image which has these changes for download

Thanks

@vidushi283 ok, closing then.