metadata:
  name: sdk-code-analysis-tools-splint
  format: "Apertis Test Definition 1.0"
  image-type: SDK
  image-arch: amd64
  type: functional
  exec-type: automated
  priority: medium
  maintainer: "Apertis Project"
  description: "Checks basic splint functionality by checking its output when run
                on a simple source file."

  expected:
    - "The test script will output a line with the test ID and the status of the
       test (PASSED or FAILED), with some additional information. An example
       output is:"
    - |
        >sdk-code-analysis-tools-splint-smoke-test: PASSED
        Program ran in 100% of samples (>= 100% required)

install:
  deps:
    - bash
    - apertis-tests
  git-repos:
    - url: https://gitlab.apertis.org/infrastructure/apertis-tests.git
      branch: master

run:
  steps:
    - "# Enter test directory:"
    - cd apertis-tests
    - "# Execute the following command:"
    - common/run-test-in-systemd --user=user --basename -- /usr/share/chaiwala-tests/sdk/automated/test-splint.sh

parse:
  fixupdict:
    FAILED: fail
    PASSED: pass
    FAIL: fail
    PASS: pass
    SKIP: skip
    UNKNOWN: unknown
  pattern: '^(?P<test_case_id>[a-zA-Z0-9_\-\./]+):\s*(?P<result>PASSED|PASS|pass|FAILED|FAIL|fail|SKIP|skip|UNKNOWN|unknown)$'
