-
Notifications
You must be signed in to change notification settings - Fork 568
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
Add browser autofill #1183
Add browser autofill #1183
Conversation
7fe33f0
to
2700881
Compare
Codecov ReportAttention:
❗ Your organization needs to install the Codecov GitHub app to enable full functionality. Additional details and impacted files@@ Coverage Diff @@
## master #1183 +/- ##
==========================================
+ Coverage 39.72% 39.74% +0.02%
==========================================
Files 53 53
Lines 8027 8063 +36
==========================================
+ Hits 3189 3205 +16
- Misses 4411 4426 +15
- Partials 427 432 +5
Flags with carried forward coverage won't be shown. Click here to find out more. ☔ View full report in Codecov by Sentry. |
2700881
to
04948a3
Compare
Hi @alFReD-NSH , Thanks for doing a PR. Are you able to provide tests for this? |
There's no tests currently for the browser provider, I'm not sure what's the reason for it, but I'm guessing it's because it's not as easy as other providers. I would appreciate if some directions or tips could be provided. I'll give it a try in couple of weeks. |
Can you reference |
I did indeed have a look at it and the actual part that runs the browser provider for a successful outcome is commented out(line 159). I tried to write a similar test with the mocked page type that already exists and I get the following error:
I tried regenerating the mocks, but didn't work, Mockery doesn't detect the difference. This could be fixable by Mockery, so I'll report an issue there. |
Apparently it's a known issue and they have a PR for it: vektra/mockery#719 |
OK - I will review this and merge it |
Hi all (paging @mapkon), I have updated the PR to include a test. I have managed to write test utilising a server and running the autoFill function against a hosted example form page. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This is brilliant @tinaboyce - I will take a look later
Fixes #1182
We could make the code a little bit smarter, or even have the field css selectors(username, password, submit button) configured from config file instead.