mlison/protractor-jasmine2-screenshot-reporter

Screenshot on a different tab?

Closed this issue · 1 comments

Hi there!

I'm performing e2e tests for a webapp that opens a new tab every time I click on a specific link.
I have some expected conditions on my new tab, but when some of those fails, the screenshot is taken for the first tab.

I was wondering if there was an option in order to always use the active tab to take screenshots, or if this is indeed a bug. In that case, has someone thought of some workaround?

Thank you all!
Regards.

I think that should be possible, if you can get a reference to that new tab/window somehow. You basically need to "register" this new instance into forkedInstances and the reporter will take a screenshot of it (read more about forked browser instances).

This is just a theory - I haven't actually tested this, though.