Skip to content

Tags: testing-library/webdriverio-testing-library

Tags

v3.2.1

build: fix selenium in github actions

Selenium is sometimes failing to come up when running
`test:selenium-standalone` in GitHub actions.

Firefox flags were incorrect, should be -headless rather than
--headless.

Prevent installing drivers since that has already been done in the
prepare script.

To prevent the tests to fail reduce the max number of capabilities to 2
when running on CI, this means only two browsers will be running at a
time.

The setupBrowser test 'it still works after session reload' is now
flaky. It seems to be related to a hanging session reload, possibly
reducing the number of available instances in capabilities has
alleviated it however. Quarantine the test so that we can build and
release while looking into it further.

v3.2.0

Verified

This commit was created on GitHub.com and signed with GitHub’s verified signature. The key has expired.
feat: better support shadow dom queries (#45)

Upgrade @testing-library/dom to better support shadow dom queries

@testing-library/dom v7 has an issue querying for elements with
aria-labels contained in a shadow dom.

v3.1.0

feat: support chaining queries

As of WebdriverIO v7.19.0 it is possible to chain custom queries as long
as they end in `$`. See the release notes for v7.19.0 here:
https://github.com/webdriverio/webdriverio/blob/v7.19.0/CHANGELOG.md

Add chainable queries to the `Browser` and `Element`
as commands of the form `{queryName}$`, for example the chainable
version of `getByText` is `getByText$`.

Infer the types for `ChainablePromiseElement` and
`ChainablePromiseArray` from the `Browser` and `Element` types, that way
we don't need to lock in a specific version of WebdriverIO's types.

To add the types of the chainable commands to the global WebdriverIO
types users now need to add `WebdriverIOQueriesChainable` to the global
`Browser`, `Element` and `ChainablePromiseElement` interfaces.

This should not break existing behaviour or types, and the chainable
custom commands should behave the same as the existing commands if the
WebdriverIO version is less than v7.19.0.

Typescript users need to use at least v4.1 as the types now make use of
template literal strings to modify the query name to include `$` at the
end.

Bump development version of WebdriverIO packages to at least v7.19.0 and
add tests for chaining queries.

v3.0.7

Verified

This commit was created on GitHub.com and signed with GitHub’s verified signature. The key has expired.
fix: null queries with prod React and Puppeteer (#38)

When returning queried elements directly from executeAsync Puppeteer
will fail and return null if the element contains circular references. Elements
in production React apps contain circular references due to React Fiber.
Puppeteer is the default driver used by wdio when no services are defined.

Instead of returning elements directly when Simmer fails add a data
attribute with an id to use as a selector. Simmer should remain the primary
method of generating selectors as it is more tolerant to scenarios where
the element is regenerated, such as when React finds a key change.

Co-authored-by: olivierwilkinson <olivier.wilkinson@gmail.com>

v3.0.6

Verified

This commit was created on GitHub.com and signed with GitHub’s verified signature. The key has expired.
fix: make lib compatible to WebdriverIO v8 (#43)

v3.0.5

fix: injecting DTL when amd define exists

https://www.ebay.com has a global define function with define.amd as an
empty object. This causes the UMD distribution of Dom Testing Library to
use the define function to expose it's methods. Since we assume the
methods are available on the TestingLibraryDom object this breaks the
library.

Modify the UMD distribution so it creates the TestingLibraryDom even
when a define function exists.

v3.0.4

Verified

This commit was created on GitHub.com and signed with GitHub’s verified signature. The key has expired.
Merge pull request #32 from testing-library/fix-typescript-compilatio…

…n-when-checking-libs

fix: typescript compilation when checking libs

v3.0.3

Verified

This commit was created on GitHub.com and signed with GitHub’s verified signature. The key has expired.
Merge pull request #30 from testing-library/fix-types-for-wdio-v7.9

fix: types when using wdio v7.9

v3.0.2

Verified

This commit was created on GitHub.com and signed with GitHub’s verified signature. The key has expired.
Merge pull request #20 from testing-library/fix-firefox

Fix firefox

v3.0.1

Verified

This commit was created on GitHub.com and signed with GitHub’s verified signature. The key has expired.
Merge pull request #17 from testing-library/fix-queries-failing-when-…

…simmer-fails

fix: queries when Simmer cannot create selector