dataSetStep.spec.tsx 782 B

1234567891011121314151617181920212223242526
  1. import {OrganizationFixture} from 'sentry-fixture/organization';
  2. import {render, screen} from 'sentry-test/reactTestingLibrary';
  3. import {DisplayType} from 'sentry/views/dashboards/types';
  4. import {DataSetStep} from 'sentry/views/dashboards/widgetBuilder/buildSteps/dataSetStep';
  5. import {DataSet} from 'sentry/views/dashboards/widgetBuilder/utils';
  6. describe('DataSetStep', () => {
  7. it('renders the spans dataset with the EAP feature flag', () => {
  8. render(
  9. <DataSetStep
  10. dataSet={DataSet.ISSUES}
  11. displayType={DisplayType.TABLE}
  12. onChange={jest.fn()}
  13. />,
  14. {
  15. organization: OrganizationFixture({
  16. features: ['dashboards-eap'],
  17. }),
  18. }
  19. );
  20. expect(screen.getByText('Spans')).toBeInTheDocument();
  21. });
  22. });