-
Notifications
You must be signed in to change notification settings - Fork 3
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
Allow selenium WebElement to be passed to expect
in place of a selector
#2
Comments
FYI: I more or less did this in my fork. I didn't spend a ton of time verifying, and I also made it a hard requirement: no more selector strings. I think this is a little true-r to Chai/BDD testing than the original chai-webdriver code. I'm happy to post a PR if you want, just noticed you bumped the version to 4.0. I mostly wanted to be able to use multiple WebDriver instances; passing the driver with the plugin initialization hampers this. |
What's the use-case for multiple driver instances? |
Iterating a test set over a different browser drivers, potentially. I'll admit, my initial impetus for the changes in the fork stemmed from some misunderstanding of the driver lifetime; I thought it was being created/destroyed per test case. Given the spec suite for this project, that's clearly not necessary. That said, I still like having the |
As a (contrived) example: Selenium's |
Hmm. If the With this issue, I was thinking of allowing an element to be passed in place of a selector, but not making |
I think it is useful, but I'm using 100% Sizzle selectors and thus would need to send a meaningless driver to set up the helper with Chai. If you check out the readme on the fork, it's just I agree it's inconsistent with the existing API, for sure, but I think it might be a reasonable major-release-worthy breaking change if you liked it as an overall direction. If not, I'm pleased with my fork so far--and really appreciate your additions! |
No description provided.
The text was updated successfully, but these errors were encountered: