Open Bug 1480337 Opened 2 years ago Updated 1 month ago
[wdspec] Move shared methods into __init
__.py file of appropriate command
59 bytes, text/x-review-board-request
The tests for all the commands specified by the WebDriver spec make use of shared methods inside their folders. To not have to duplicate those methods across all test files, move them into the __init__.py file. https://searchfox.org/mozilla-central/source/testing/web-platform/tests/webdriver/tests
Comment on attachment 8997431 [details] Bug 1480337 - [wdspec] Move shared methods into __init__.py file for each command. https://reviewboard.mozilla.org/r/261204/#review268268 There’s a lot of test failures because the HTTP request functions carry the same name as the module they’re in. If you can solve that, this looks OK.
Attachment #8997431 - Flags: review?(ato) → review+
The underlying problem here is actually not that the shared methods have the same name as the module, but that the fixtures don't care about the imported method, but try to make use of the global module. I assume that this happens because of the way how those are executed by pytest. Also it could mean that this is a bug in pytest. I will investigate and file a new issue against pytest if necessary.
Also please note that I'm not able to see those failures locally when I run the tests with `mach`. So maybe there is a different version of pytest in use, which might mean a new regression or a fix in one of the latest releases.
Assignee: hskupin → nobody
Status: ASSIGNED → NEW
Priority: P2 → P3
You need to log in before you can comment on or make changes to this bug.