Closed
Description
Have you read the Troubleshooting section?
Yes
Plugin version
7.5.0
ESLint version
9.28.0
Node.js version
22.15.0
Bug description
When upgrading the eslint-plugin-testing-library
to the latest release today I have found out few new ESLint no-node-access
rule warnings which seems to be a false-positives.
Steps to reproduce
import { render, screen } from '@testing-library/react';
import userEvent from '@testing-library/user-event';
it('outputs false-positive warnings', async () => {
render(<button>Test</button>);
const user = userEvent.setup();
await user.click(screen.getByText('Test'));
});
Error output/screenshots
ESLint configuration
ESLint flat config chunk related to Testing Library:
{
files: ['**/*-test.[jt]s?(x)'],
...testingLibrary.configs['flat/react'],
}
Rule(s) affected
no-node-access
Anything else?
No response
Do you want to submit a pull request to fix this bug?
No