Reputation: 1
I have link that will open a new page to do some task. I can only proceed further only after allowing camera permissions.
popup window
First a confirmation popup appears which ask for camera permissions. After clicking on allow button browser permission popup appears. it's similar to all pops that appears when we visit any website
I have a feature file written in Gherkin syntax and a step definition file written using capybara syntax.
step definition
Then('I click test link') do
test_window = window_opened_by do
find(:css, "a[href='example.com/test']").click()
# sleep(5)
end
within_window test_window do
click_button 'Allow'
end
sleep(10)
end
After clicking allow button browser permission pop appears.Please check the attached images. I need to allow that permission. can someone suggest how to do that using capybara-cucumber with selenium chromeDriver.
If you have any idea how i can do the same thing in cypress please suggest. Cypress is not allowing camera permission. I have already used a npm module but it didn't worked for me. Any other alternative to do the same ??
Upvotes: 0
Views: 771
Reputation: 169
have you tried to add the --use-fake-ui-for-media-stream
or --use-fake-device-for-media-stream
argument when you set the desired capabilities?
Upvotes: 1