Assertions: Use expect() to assert the expected behavior.?
Example:
import { render, screen, fireEvent } from '@testing-library/react';
import MyComponent from './MyComponent';
test('renders the component and interacts', () => {
render(<MyComponent />);
const button = screen.getByText('Click me');
fireEvent.click(button);
expect(screen.getByText('Clicked!')).toBeInTheDocument();
});