Verified Commit d4c12451 authored by Alberto Miranda's avatar Alberto Miranda ♨️
Browse files

dep_scripts: Enable scripts testing in .gitlab-ci.yml

parent af2dc5d8
Loading
Loading
Loading
Loading
+19 −0
Original line number Diff line number Diff line
@@ -12,6 +12,7 @@ variables:
  INTEGRATION_TESTS_BIN_PATH:   "${CI_PROJECT_DIR}/gkfs/install/share/gkfs/tests/integration"
  COVERAGE_PATH:                "${CI_PROJECT_DIR}/gkfs/build/.coverage"
  PYTEST:                       "${CI_PROJECT_DIR}/gkfs/install/share/gkfs/tests/integration/pytest-venv/bin/py.test"
  BATS:                         "${CI_PROJECT_DIR}/tests/scripts/bats/bin/bats"
  LD_LIBRARY_PATH:              "${CI_PROJECT_DIR}/deps/install/lib:${CI_PROJECT_DIR}/deps/install/lib64"
  # Configuration variables
  GKFS_LOG_LEVEL:               "100"
@@ -97,6 +98,24 @@ gkfwd:
## Testing
################################################################################

## == tests for scripts ====================
scripts:
  stage: test
  image: gekkofs/testing:0.8.0
  needs: []
  parallel:
    matrix:
      - SUBTEST: [ dl_dep.sh, compile_dep.sh ]
  script:
    - mkdir -p ${BUILD_PATH}/tests/scripts
    - cd ${BUILD_PATH}/tests/scripts
    - ${BATS} -r ${CI_PROJECT_DIR}/tests/scripts/${SUBTEST} --formatter junit > report.xml
  artifacts:
    expire_in: 1 week
    reports:
      junit: ${BUILD_PATH}/tests/scripts/report.xml


## == integration tests for gkfs ===========
gkfs:integration:
  stage: test
+3 −3
Original line number Diff line number Diff line
@@ -120,7 +120,7 @@ teardown() {
        run compile_dep.sh -n -d "${dep}" ${source_path} ${install_path}

        assert_output --regexp \
"CORES = 8 \(default\)
"CORES = [0-9]+ \(default\)
Sources download path = ${source_path}
Installation path = ${install_path}
Profile name: default
@@ -150,7 +150,7 @@ Done"
            run compile_dep.sh -n -d "${dep}@${pn}" ${source_path} ${install_path}

            assert_output --regexp \
"CORES = 8 \(default\)
"CORES = [0-9]+ \(default\)
Sources download path = ${source_path}
Installation path = ${install_path}
Profile name: ${pn}
@@ -185,7 +185,7 @@ Done"
                run compile_dep.sh -n -d "${dep}@${pn}" ${source_path} ${install_path}

                assert_output --regexp \
"CORES = 8 \(default\)
"CORES = [0-9]+ \(default\)
Sources download path = ${source_path}
Installation path = ${install_path}
Profile name: ${pn}