Closed
Bug 1127823
Opened 11 years ago
Closed 11 years ago
Make use of unique parameter types in close_all() of Windows class
Categories
(Testing :: Firefox UI Tests, defect)
Tracking
(Not tracked)
RESOLVED
FIXED
mozilla38
People
(Reporter: whimboo, Assigned: galgeek)
Details
Attachments
(1 file)
This is from the discussion on this PR:
https://github.com/mozilla/firefox-ui-tests/pull/50/files#r23735855
As of now the close_all() method allows window exceptions being passed in as handles or BaseWindow. Chris mentioned his concerns about this because it can be disruptive.
So we should figure out what we want to do here. I'm happy to let this library and especially this method work with BaseWindow instances. So usually all of our tests make use of those. Handles shouldn't be touched at all. And in the unit tests we can simply create a BaseWindow class from a handle to push it into this method.
Chris, would that be a proper solution for you?
Flags: needinfo?(cmanchester)
Comment 1•11 years ago
|
||
Sorry, I wasn't clear. I find APIs that take a list or a single element and convert it to a list internally really problematic. I know from past discussions that this is pretty common in Python APIs, and I'm probably in a minute minority on this point. I just mentioned it in case you were sympathetic and were OK with just always passing a list.
Flags: needinfo?(cmanchester)
Reporter | ||
Comment 2•11 years ago
|
||
Well, I have no real objection here, so I'm happy to go the route what you propose. Barbara, maybe you can work on a fix today?
Summary: Make use of unique parameter types in Windows class (especially close_all) → Make use of unique parameter types in close_all() of Windows class
Assignee | ||
Comment 3•11 years ago
|
||
As I’ve commented on github, I am sympathetic both to Henrik's suggestion that close_all should expect a particular parameter type and to Chris’s distaste for APIs that convert a single element to a list, so I've implemented both here, in case that's what everybody wants after all.
Assignee: nobody → galgeek
Attachment #8557540 -
Flags: review?(hskupin)
Attachment #8557540 -
Flags: feedback?(cmanchester)
Assignee | ||
Comment 4•11 years ago
|
||
I've updated the github PR per Henrik's feedback there.
Comment 5•11 years ago
|
||
Comment on attachment 8557540 [details] [review]
github_pull_request.txt
I think this is an improvement, thanks!
Attachment #8557540 -
Flags: feedback?(cmanchester) → feedback+
Assignee | ||
Comment 6•11 years ago
|
||
I've again updated the github PT per Henrik's feedback there.
Reporter | ||
Updated•11 years ago
|
Attachment #8557540 -
Flags: review?(hskupin) → review+
Reporter | ||
Comment 7•11 years ago
|
||
PR merged as https://github.com/mozilla/firefox-ui-tests/commit/b6c5183d1ceeaeacc315d9d56222559ed8504a3c
Status: NEW → RESOLVED
Closed: 11 years ago
Flags: in-testsuite+
Resolution: --- → FIXED
Target Milestone: --- → Firefox 38
Updated•10 years ago
|
Product: Mozilla QA → Testing
You need to log in
before you can comment on or make changes to this bug.
Description
•