---
inputType: "CA10__CaAwsLambdaFunction__c"
testData:
  - file: "test-data.json"
importExtracts:
  - file: "/types/CA10__CaAwsLambdaFunction__c/object.extracts.yaml"
conditions:
  - status: "INCOMPLIANT"
    currentStateMessage: "Lambda Function tracing with AWS X-Ray is not enabled."
    remediationMessage: "Enable Function X-Ray tracing."
    check:
      IS_EQUAL:
        left:
          EXTRACT: "CA10__tracingConfigResponseMode__c"
        right:
          TEXT: "PassThrough"
  - status: "COMPLIANT"
    currentStateMessage: "Lambda Function tracing with AWS X-Ray is enabled."
    check:
      IS_EQUAL:
        left:
          EXTRACT: "CA10__tracingConfigResponseMode__c"
        right:
          TEXT: "Active"
otherwise:
  status: "UNDETERMINED"
  currentStateMessage: "Unexpected values in the field."
