awsLambdaFunctionSelect.spec.tsx 760 B

123456789101112131415161718192021
  1. import {render, screen} from 'sentry-test/reactTestingLibrary';
  2. import AwsLambdaFunctionSelect from 'sentry/views/integrationPipeline/awsLambdaFunctionSelect';
  3. describe('AwsLambdaFunctionSelect', () => {
  4. it('choose lambdas', () => {
  5. render(
  6. <AwsLambdaFunctionSelect
  7. initialStepNumber={0}
  8. lambdaFunctions={[
  9. {FunctionName: 'lambdaA', Runtime: 'nodejs12.x'},
  10. {FunctionName: 'lambdaB', Runtime: 'nodejs10.x'},
  11. {FunctionName: 'lambdaC', Runtime: 'nodejs10.x'},
  12. ]}
  13. />
  14. );
  15. expect(screen.getByRole('checkbox', {name: 'lambdaB'})).toBeInTheDocument();
  16. expect(screen.getByRole('button', {name: 'Finish Setup'})).toBeInTheDocument();
  17. // TODO: add assertion for form post
  18. });
  19. });