Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Native Support for iFrames #227

Open
renelux opened this issue Dec 23, 2015 · 2 comments
Open

Native Support for iFrames #227

renelux opened this issue Dec 23, 2015 · 2 comments

Comments

@renelux
Copy link
Contributor

renelux commented Dec 23, 2015

Please look at the following proposal for adding support for iFrames to SeLion. We are running into the issue where some pages contain an iframe that we need to interact with. We usually create a separate page object and switch to the frame before interacting with it.

This works but our test cases start to look a little more messy, as we can't rely on all the features of SeLion anymore.

Proposal:

  1. Create an element similar to Container which represents an iframe with subelements.
  2. If we interact with an element in a iframe it should automatically switch to the iframe.
  3. Add the ability to automatically switch back to main window when taking screenshot.

For 2 and 3 the behavior should be configurable so that people can change the behavior to their needs. And this should be supported on a global level and on per iframe object level through Yaml.

@renelux
Copy link
Contributor Author

renelux commented Dec 23, 2015

@mach6 can you please look at it. If approved I can work on it 😄

@mach6
Copy link
Contributor

mach6 commented Dec 23, 2015

@renelux Other than the Config need, I think you could accomplish this with a custom element. That said, I can see the value of having support for something like this in the SeLion code. My only suggestions are to;

  1. Consider putting a solution that more generically solves the problem for anything where a call to driver.switchTo().window(handle) is needed.
  2. Let's think of it more generically as a "view".
  3. Let's include support for mobile, in the case of hybrid apps that need to driver.switchTo() web and app views.

Thanks for the suggestion! I look forward to seeing what you come up with!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants