-
-
Notifications
You must be signed in to change notification settings - Fork 8.2k
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
[py] Fix converting list of tuples to str in send_keys #9330
Conversation
Should I write a regression test for this PR? |
Please add a regression test for this please.
…On Mar 29, 2021, 11:22 AM +0100, Sergey Fursov ***@***.***>, wrote:
Should I write a regression test for this PR?
—
You are receiving this because you are subscribed to this thread.
Reply to this email directly, view it on GitHub, or unsubscribe.
|
hi @AutomatedTester, actually tests for the remote webdriver fail with the actual implementation and my update fixes them, they just are not running in GH actions. P.S. I found it too difficult to run the project's test suite locally. I ended up running pytest manually without using bazel at all. Did you consider writing an instruction on how to run tests properly using bazel? |
The tests are passing, what do you mean they aren't? I just looked at https://github.com/SeleniumHQ/selenium/runs/2318807884?check_suite_focus=true#step:9:121 and it's passing when I run locally. davidburns in ~/development/selenium on trunk λ bazel test //py:test-remote-test/selenium/webdriver/common/upload_tests.py
INFO: Invocation ID: 41001f34-9660-4861-a7bb-cbdde03f4f74
INFO: Analyzed target //py:test-remote-test/selenium/webdriver/common/upload_tests.py (1 packages loaded, 15 targets configured).
INFO: Found 1 test target...
Target //py:test-remote-test/selenium/webdriver/common/upload_tests.py up-to-date:
bazel-bin/py/test-remote-test/selenium/webdriver/common/upload_tests.py-runner.py
bazel-bin/py/test-remote-test/selenium/webdriver/common/upload_tests.py
INFO: Elapsed time: 11.927s, Critical Path: 10.44s
INFO: 2 processes: 2 local.
INFO: Build completed successfully, 2 total actions
//py:test-remote-test/selenium/webdriver/common/upload_tests.py PASSED in 9.9s
Executed 1 out of 1 test: 1 test passes.
There were tests whose specified size is too big. Use the --test_verbose_time
INFO: Build completed successfully, 2 total actions The same tests are passing with this patch too so there is clearly a difference in the way you're using it which is why another test would be awesome |
The reason we use Bazel is to prevent "it works on my machine" errors. It only allows specific env vars to be used. You can see them here https://github.com/SeleniumHQ/selenium/blob/trunk/.bazelrc#L33-L42 The error you're getting is that Marionette can't find the file. Is this happening with bazel or via a different method? It's not saying the wrong type or anything is being passed it, Firefox is saying that it can't find the file at all in your last comment. |
How do you handle problems like "Bazel" doesn't work on my machine"? :) I use a different method, running pytest directly and connecting to ready-to-use |
FWIW, |
but it still has access to the local filesystem, right? |
Yes, everything is running locally, no docker containers are involved. |
As @diemol says, we build and give the python tests to the server that is built as part of the task. You can see the bazel target in https://github.com/SeleniumHQ/selenium/blob/trunk/py/BUILD.bazel#L347-L369 The This can all be solved by you adding a failing test so that we make sure that we never regress this code. You will see it start failing on github actions too then we definitely know that it's not a "works on my machine" type problem |
What I'm trying to say, is that the current test suite already catches the bug in code and it fails when the "real" remote webdriver is used for testing. Let me try to think how to assert this in tests without reworking the tests running method... |
hey guys, I've added an additional test for checking that the actual file upload happened to the machine with the remote webdriver. Could you please check? |
Kudos, SonarCloud Quality Gate passed! |
Co-authored-by: David Burns <[email protected]>
Description
Fixes a bug in converting a tuple of values passed to WebElement.send_keys method
Motivation and Context
Detecting local files is broken in the 4.0.0.b2.post1 version
Types of changes