Releases: testing-library/dom-testing-library
Releases · testing-library/dom-testing-library
v8.4.0
v8.3.0
v8.2.0
v8.1.1
v8.1.0
v8.0.0
8.0.0 (2021-06-23)
Recommendations
- If you're using
jest
fake timers make sure you use modern timers
jest 27:jest 26:-jest.useFakeTimers('legacy') +jest.useFakeTimers('modern') // jest.config.js -"timers": "legacy", +"timers": "modern",
-jest.useFakeTimers() +jest.useFakeTimers('modern') // jest.config.js -"timers": "legacy", +"timers": "modern",
chore
BREAKING CHANGES
- Remove deprecated
waitFormDOMChange
- Remove deprecated
waitForElement
- The
timeout
inwaitFor(callback, { interval, timeout } )
now uses the same clock asinterval
. Previouslytimeout
was always using the real clock whileinterval
was using the global clock which could've been mocked out. For the old behavior I'd recommendwaitFor(callback, { interval, timeout: Number.POSITIVE_INFINITY })
and rely on your test runner to timeout considering real timers. <script />
,<style />
and comment nodes are now ignored by default inprettyDOM
.If you whish to return to the old behavior, use a customfilterNode
function. In this caseprettyDOM(element, { filterNode: () => true })
.- node 10 is no longer supported. It reached its end-of-life on 30.04.2021.
v8.0.0-alpha.7
v8.0.0-alpha.6
8.0.0-alpha.6 (2021-06-12)
Features
BREAKING CHANGES
- node 10 is no longer supported. It reached its end-of-life on 30.04.2021.