jest-dom icon indicating copy to clipboard operation
jest-dom copied to clipboard

:owl: Custom jest matchers to test the state of the DOM

Results 159 jest-dom issues
Sort by recently updated
recently updated
newest added

**What**: This uses `.mjs` for esm files being exported from the package, since the package itself is not `"type": "module"`. I also marked it as explicitly `"type": "commonjs"` for good...

- `@testing-library/react` version: 13.2.0 - Testing Framework and version: jest 28.1.0 - DOM Environment: "jest-environment-jsdom": "^28.1.0", "react": "^18.1.0", ### Relevant code or config: ```ts import { render } from '@testing-library/react';...

Hi Im curious if Jest DOM can support Web Components using the Shadow DOM For example Ive got the following test ```javascript const defaultElement = document.createElement('custom-element') expect(defaultElement.shadow.querySelector('template')).toContainHTML('') // also tried...

- `@testing-library/jest-dom` version: 5.16.4 - `@testing-library/vue` version: 5.8.3 - `node` version: 14.20 - `npm` version: 6.14 ### Relevant code or config: ```js import { render, screen } from '@testing-library/vue'; import...

- `@testing-library/jest-dom` version: 5.14.1 - `node` version: 14.15.4 - `npm` version: 6.14.13 - `react-testing-library` version: 11.2.7 ### Relevant code or config: You could find everything in the repository in the...

- `@testing-library/jest-dom` version: 5.14.3 - `node` version: 16.13.2 - `npm` (or `yarn`) version: 8.1.2 ### Relevant code or config: ```js import { Select } from '@mui/material'; ... {label} {options} ```...

**What**: Information on installing typescript types from `@types/jest-dom__types` **Why**: These instructions are critical for using Typescript, yet I haven't seen any instructions. **How**: In `readme.md`. > \ I'm not sure...

### Describe the feature you'd like: Suppose you want to match text from a paragraph containing `` elements for custom line break handling: ```tsx const MyGreatTextComponent = () => {...

bug

- `@testing-library/jest-dom` version: 5.16.1 - `node` version: 14.17.0 - `yarn` version: 1.22.17 - `@testing-library/react` version: 12.1.2 I am using `vitest` instead of `jest` for testing a React component lib in...

bug
BREAKING CHANGE

- `@testing-library/jest-dom` version: 5.16.4 - `node` version: 16.15.0 - `npm` (or `yarn`) version: 8.5.5 ### Relevant code or config: This test works fine: ```js test('window.CSS is not present', () =>...