koa.spec.tsx 767 B

12345678910111213141516171819202122232425
  1. import {render, screen} from 'sentry-test/reactTestingLibrary';
  2. import {StepTitle} from 'sentry/components/onboarding/gettingStartedDoc/step';
  3. import {GettingStartedWithKoa, steps} from './koa';
  4. describe('GettingStartedWithKoa', function () {
  5. it('all products are selected', function () {
  6. const {container} = render(<GettingStartedWithKoa dsn="test-dsn" />);
  7. // Steps
  8. for (const step of steps({
  9. installSnippet: 'test-install-snippet',
  10. importContent: 'test-import-content',
  11. initContent: 'test-init-content',
  12. hasPerformanceMonitoring: true,
  13. })) {
  14. expect(
  15. screen.getByRole('heading', {name: step.title ?? StepTitle[step.type]})
  16. ).toBeInTheDocument();
  17. }
  18. expect(container).toSnapshot();
  19. });
  20. });