selenium webdriver - How to Print Browser console logs using Cucumber Ruby Automation? -


can please on printing console logs generate in web browser errors in cucumber capybara test automation? using phantomjs webdriver below:

capybara::selenium::driver.new(app, :browser => :phantomjs, desired_capabilities: { 'phantomjs.cli.args' => ['--ignore-ssl-errors=yes']

i want capture browser js console logs , print while need on automation execution

since you're using selenium can try

page.driver.browser.manage.logs.get("browser") 

note: i've never tried phantomjs browser


Comments

Popular posts from this blog

php - Wordpress website dashboard page or post editor content is not showing but front end data is showing properly -

How to get the ip address of VM and use it to configure SSH connection dynamically in Ansible -

javascript - Get parameter of GET request -