output.d.ts 1.5 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243
  1. import { Ora } from 'ora';
  2. import { TestOutput } from './scan/results';
  3. import { TestCommandResult } from '../../../../cli/commands/types';
  4. import { IacOrgSettings } from '../../../../cli/commands/test/iac/local-execution/types';
  5. import { CustomError, FormattedCustomError } from '../../../errors';
  6. import { SnykIacTestError } from './errors';
  7. export declare function buildOutput({ scanResult, testSpinner, orgSettings, options, }: {
  8. scanResult: TestOutput;
  9. testSpinner?: Ora;
  10. orgSettings: IacOrgSettings;
  11. options: any;
  12. }): TestCommandResult;
  13. interface ResponseData {
  14. response: string;
  15. json: string;
  16. sarif: string;
  17. }
  18. export declare class NoSuccessfulScansError extends FormattedCustomError {
  19. json: string | undefined;
  20. jsonStringifiedResults: string | undefined;
  21. sarifStringifiedResults: string | undefined;
  22. fields: {
  23. path: string;
  24. } & Record<string, string>;
  25. constructor(responseData: Omit<ResponseData, 'response'>, errors: SnykIacTestError[], options: {
  26. json?: boolean;
  27. sarif?: boolean;
  28. });
  29. get path(): string;
  30. set path(path1: string);
  31. }
  32. export declare class NoLoadableInputError extends NoSuccessfulScansError {
  33. constructor(responseData: Omit<ResponseData, 'response'>, errors: SnykIacTestError[], options: {
  34. json?: boolean;
  35. sarif?: boolean;
  36. });
  37. }
  38. export declare class FoundIssuesError extends CustomError {
  39. jsonStringifiedResults: string;
  40. sarifStringifiedResults: string;
  41. constructor(responseData: ResponseData);
  42. }
  43. export {};