spring-boot.spec.tsx 647 B

12345678910111213141516171819202122
  1. import {render, screen} from 'sentry-test/reactTestingLibrary';
  2. import {StepTitle} from 'sentry/components/onboarding/gettingStartedDoc/step';
  3. import {GettingStartedWithSpringBoot, steps} from './spring-boot';
  4. describe('GettingStartedWithSpringBoot', function () {
  5. it('renders doc correctly', function () {
  6. const {container} = render(<GettingStartedWithSpringBoot dsn="test-dsn" />);
  7. // Steps
  8. for (const step of steps({
  9. dsn: 'test-dsn',
  10. })) {
  11. expect(
  12. screen.getByRole('heading', {name: step.title ?? StepTitle[step.type]})
  13. ).toBeInTheDocument();
  14. }
  15. expect(container).toSnapshot();
  16. });
  17. });