Commit 8bd15c8b authored by Jan Kiene's avatar Jan Kiene
Browse files

convert msan and asan MR jobs to use pytest instead of self_test.py

parent 0d466098
Loading
Loading
Loading
Loading
+18 −10
Original line number Diff line number Diff line
@@ -449,17 +449,22 @@ codec-msan:
    - *print-common-info
    - make clean
    - make -j CLANG=1
    - python3 scripts/self_test.py -z console --create | tee test_output.txt
    - run_errors=$(cat test_output.txt | grep -ic "run errors") || true
    - if [ $run_errors != 0 ] ; then echo "Run errors in self_test.py with Clang memory-sanitizer"; exit 1; fi
    - testcase_timeout=180
    - exit_code=0
    - python3 -m pytest tests/codec_be_on_mr_nonselection/test_param_file.py -v --update_ref 1 -m create_ref --html=report.html --self-contained-html --junit-xml=report-junit.xml --testcase_timeout=$testcase_timeout || exit_code=$?
    - zero_errors=$(cat report-junit.xml | grep -c 'errors="0"') || true
    - if [ $zero_errors != 0 || exit_code != 0 ] ; then echo "Run errors found by Clang memory-sanitizer"; exit 1; fi
  artifacts:
    name: "mr-$CI_MERGE_REQUEST_IID--sha-$CI_COMMIT_SHORT_SHA--stage-$CI_JOB_STAGE--results"
    expire_in: 1 week
    when: always
    paths:
      - scripts/ref/logs/
      - test_output.txt
      - report-junit.xml
      - report.html
    expose_as: "msan selftest results"
    reports:
      junit:
        - report-junit.xml

# code selftest testvectors with address-sanitizer binaries
codec-asan:
@@ -472,17 +477,20 @@ codec-asan:
    - *print-common-info
    - make clean
    - make -j CLANG=2
    - python3 scripts/self_test.py -z console --create | tee test_output.txt
    - run_errors=$(cat test_output.txt | grep -ic "run errors") || true
    - if [ $run_errors != 0 ] ; then echo "Run errors in self_test.py with Clang address-sanitizer"; exit 1; fi
    - python3 -m pytest tests/codec_be_on_mr_nonselection/test_param_file.py -v --update_ref 1 -m create_ref --html=report.html --self-contained-html --junit-xml=report-junit.xml --testcase_timeout=$testcase_timeout || exit_code=$?
    - zero_errors=$(cat report-junit.xml | grep -c 'errors="0"') || true
    - if [ $zero_errors != 0 || exit_code != 0 ] ; then echo "Run errors found by Clang address-sanitizer"; exit 1; fi
  artifacts:
    name: "mr-$CI_MERGE_REQUEST_IID--sha-$CI_COMMIT_SHORT_SHA--stage-$CI_JOB_STAGE--results"
    expire_in: 1 week
    when: always
    paths:
      - scripts/ref/logs/
      - test_output.txt
      - report-junit.xml
      - report.html
    expose_as: "asan selftest results"
    reports:
      junit:
        - report-junit.xml

# code selftest testvectors with address-sanitizer binaries
codec-usan: