Skip to content
This repository was archived by the owner on Feb 4, 2018. It is now read-only.
This repository was archived by the owner on Feb 4, 2018. It is now read-only.

allow simplified wait for multiple custom elements #10

@devopsmariocom

Description

@devopsmariocom

We have encounter case where we need to test multiple elements in single test as you can see here https://github.com/wc-catalogue/blaze-elements/blob/master/packages/collapsible/Collapsible.test.tsx#L53

So I have got idea that we can enhance waitFor functionality by allowing array of selectors for each element we want to wait for as argument.

Something like this:

    mount(
      <div>
        <SomeElement id="first"/>
        <SomeElement id="second"/>
      </div>
    ).waitFor(['#first', '#second'])
    .then(...)

as an alternative we can also add new method(waitForAll?) with will just use waitFor under the hood.

Let me know if you like the idea and I can try simple pull request for that.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions