Closed Bug 1945113 Opened 1 year ago Closed 1 year ago

Add "isNonEmptyArray" assertion method to Assert.sys.mjs

Categories

(Remote Protocol :: WebDriver BiDi, task, P3)

task

Tracking

(firefox137 fixed)

RESOLVED FIXED
137 Branch
Tracking Status
firefox137 --- fixed

People

(Reporter: Sasha, Assigned: speneth1, Mentored)

Details

(Whiteboard: [lang=js][webdriver:m15][webdriver:external][webdriver:relnote] )

Attachments

(1 file)

Follow-up from review: https://phabricator.services.mozilla.com/D235927#inline-1310622. Since the WebDriver BiDi spec has quite a few commands which expect the arguments to be non-empty arrays, we have a lot of places (e.g. script, session modules) where we required to check it, so it might be useful to reduce code duplication to add a new assertion method to Assert.sys.mjs.

Mentor: aborovova
Priority: -- → P3
Whiteboard: [lang=js]

May I take on this bug if it's still available?

Flags: needinfo?(aborovova)

(In reply to Spencer from comment #1)

May I take on this bug if it's still available?

Yes, go ahead!
Let me know if you have any questions :)

Flags: needinfo?(aborovova)
  • Added isNonEmptyArray assert to Assert.sys.mjs.
  • Refactored code that checked if an array was non-empty and replaced
    each occurrence with an isNonEmptyArray callback.
Assignee: nobody → speneth1
Status: NEW → ASSIGNED
Pushed by aborovova@mozilla.com: https://hg.mozilla.org/integration/autoland/rev/d91ce8f06ce5 [WebDriverBiDi] Add isNonEmptyArray assertion method to Assert.sys.mjs. r=Sasha,webdriver-reviewers
Status: ASSIGNED → RESOLVED
Closed: 1 year ago
Resolution: --- → FIXED
Target Milestone: --- → 137 Branch

Thank you Spencer for another nice addition to our code!

Whiteboard: [lang=js] → [lang=js][webdriver:m15][webdriver:external]
Whiteboard: [lang=js][webdriver:m15][webdriver:external] → [lang=js][webdriver:m15][webdriver:external][webdriver:relnote]
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Creator:
Created:
Updated:
Size: