import '@testing-library/jest-dom'; import { render, screen } from '@testing-library/react'; import Chatbot from './Chatbot'; describe('Chatbot', () => { it('should render Chatbot with default display mode', () => { render(Chatbot Content); expect(screen.getByText('Chatbot Content')).toBeTruthy(); }); it('should render Chatbot with custom ariaLabel', () => { render(Chatbot Content); expect(screen.getByLabelText('Chatbot')).toBeTruthy(); }); it('should render Chatbot with custom className', () => { const { container } = render( Chatbot Content ); const chatbotElement = container.querySelector('.custom-class'); expect(chatbotElement).toBeInTheDocument(); }); it('should not render Chatbot', () => { render(Chatbot Content); expect(screen.queryByLabelText('Chatbot')).toBeFalsy(); }); it('should handle isCompact', () => { render( Chatbot Content ); expect(screen.getByTestId('chatbot')).toHaveClass('pf-m-compact'); }); });