CustomButton.spec.tsx 351 B

1234567891011
  1. import CustomButton from '../../customButton/CustomButton';
  2. import { render } from '@testing-library/react';
  3. describe('Test CustomButton', () => {
  4. test('test button props', () => {
  5. const result = render(
  6. <CustomButton variant="contained">test</CustomButton>
  7. );
  8. expect(result.getByText('test').textContent).toBe('test');
  9. });
  10. });