Commit 16e1eb7c authored by norvell's avatar norvell
Browse files

Merge branch 'pre-job-for-pytest-to-ref' into 'main'

Pre job for pytest to ref

See merge request !48
parents 92637832 bc661ff2
Loading
Loading
Loading
Loading
+30 −1
Original line number Diff line number Diff line
@@ -147,6 +147,15 @@ workflow:
    - if: $CI_PIPELINE_SOURCE == 'push'
      when: never

.rules-pytest-to-ref-pre:
  rules:
    - if: $CI_PIPELINE_SOURCE == 'web'
    - if: $CI_PIPELINE_SOURCE == 'schedule'
    - if: $CI_PIPELINE_SOURCE == 'push'
      when: never
    - if: $CI_PIPELINE_SOURCE == 'merge_request_event'
      when: never

.rules-pytest-to-ref-short:
  rules:
    - if: $PYTEST_MLD_SHORT # Set by scheduled pipeline
@@ -240,9 +249,10 @@ workflow:
    - if [ ! -d "$TESTV_DIR" ]; then mkdir -p $TESTV_DIR; fi
    - cp -r scripts/testv/* $TESTV_DIR/

# This anchor is the basis for manual and scheduled tests comparing to float ref (ivas-float-update)
.ivas-pytest-anchor: &ivas-pytest-anchor
  stage: test
  needs: ["build-codec-linux-make"]
  needs: ["build-codec-linux-make", "pytest-to-ref-pre"]
  timeout: "480 minutes"
  variables:
    # keep "mld" in artifact name for backwards compatibility reasons
@@ -267,6 +277,8 @@ workflow:
    - else
    -    testcase_timeout=$TESTCASE_TIMEOUT_STV
    - fi
    - FLOAT_REF_COMMIT=$(cat "$FLOAT_REF_COMMIT_FILE")
    - echo "FLOAT_REF_COMMIT=$FLOAT_REF_COMMIT"

    - python3 ci/remove_unsupported_testcases.py $PRM_FILES
    - if [ $LEVEL_SCALING != "1.0" ]; then
@@ -913,6 +925,23 @@ clang-format-check:
    name: "$ARTIFACT_BASE_NAME"
    expose_as: "formatting patch"


# This job runs in manual jobs and scheduled jobs that compares to the float reference.
# It fetches the latest commit of ivas-float-update and stores in FLOAT_COMMIT_REF
pytest-to-ref-pre:
  extends:
    - .job-linux
    - .rules-pytest-to-ref-pre
  stage: prevalidate
  script:
    - git fetch origin ivas-float-update
    - FLOAT_REF_COMMIT="$(git rev-parse "origin/ivas-float-update")"
    - echo "$FLOAT_REF_COMMIT" > $FLOAT_REF_COMMIT_FILE
  artifacts:
    paths:
      - $FLOAT_REF_COMMIT_FILE
    reports:
      dotenv: commits.env
# ---------------------------------------------------------------
# Build jobs
# ---------------------------------------------------------------