diff --git a/.github/workflows/scripts/test_init_scripts.sh b/.github/workflows/scripts/test_init_scripts.sh index 048fba81..8e3a522d 100755 --- a/.github/workflows/scripts/test_init_scripts.sh +++ b/.github/workflows/scripts/test_init_scripts.sh @@ -1,7 +1,16 @@ #!/bin/bash -EESSI_VERSION="2023.06" export LMOD_PAGER=cat +if [ -z ${EESSI_VERSION} ] || [ ! -d /cvmfs/software.eessi.io/versions/${EESSI_VERSION} ]; then + echo "\$EESSI_VERSION has to be set to a valid EESSI version." + exit 1 +fi + +if [ -z ${EXPECTED_EASYBUILD_VERSION} ]; then + echo "\$EXPECTED_EASYBUILD_VERSION has to be set to an EasyBuild version that is expected to be available in EESSI version ${EESSI_VERSION}." + exit 1 +fi + # initialize assert framework if [ ! -d assert.sh ]; then echo "assert.sh not cloned." @@ -30,15 +39,16 @@ for shell in ${SHELLS[@]}; do assert_raises 'echo "${MODULE_SECTIONS[1]}" | grep -E "$PATTERN"' # TEST 3: Check if module overviews second section is the EESSI init module assert "echo ${MODULE_SECTIONS[4]}" "/cvmfs/software.eessi.io/versions/$EESSI_VERSION/init/modules" - # Test 4: Load Python module and check version - command="$shell -c 'source init/lmod/$shell 2>/dev/null; module load Python/3.10.8-GCCcore-12.2.0; python --version'" - expected="Python 3.10.8" - assert "$command" "$expected" - # Test 5: Load Python module and check path - PYTHON_PATH=$($shell -c "source init/lmod/$shell 2>/dev/null; module load Python/3.10.8-GCCcore-12.2.0; which python") - PATTERN="/cvmfs/software\.eessi\.io/versions/$EESSI_VERSION/software/linux/x86_64/(intel/haswell|amd/zen3)/software/Python/3\.10\.8-GCCcore-12\.2\.0/bin/python" - echo "$PYTHON_PATH" | grep -E "$PATTERN" - assert_raises 'echo "$PYTHON_PATH" | grep -E "$PATTERN"' + # Test 4: Load EasyBuild module and check version + # eb --version outputs: "This is EasyBuild 5.1.1 (framework: 5.1.1, easyblocks: 5.1.1) on host ..." + command="$shell -c 'source init/lmod/$shell 2>/dev/null; module load EasyBuild/${EXPECTED_EASYBUILD_VERSION}; eb --version | cut -d \" \" -f4'" + assert "$command" "$EXPECTED_EASYBUILD_VERSION" + # Test 5: Load EasyBuild module and check path + EASYBUILD_PATH=$($shell -c "source init/lmod/$shell 2>/dev/null; module load EasyBuild/${EXPECTED_EASYBUILD_VERSION}; which eb") + # escape the dots in ${EASYBUILD_VERSION} + PATTERN="/cvmfs/software\.eessi\.io/versions/$EESSI_VERSION/software/linux/x86_64/(intel/haswell|amd/zen3)/software/EasyBuild/${EXPECTED_EASYBUILD_VERSION//./\\.}/bin/eb" + echo "$EASYBUILD_PATH" | grep -E "$PATTERN" + assert_raises 'echo "$EASYBUILD_PATH" | grep -E "$PATTERN"' #End Test Suite assert_end "source_eessi_$shell" diff --git a/.github/workflows/test-eb-hooks.yml b/.github/workflows/test-eb-hooks.yml index 57b0d650..ef636291 100644 --- a/.github/workflows/test-eb-hooks.yml +++ b/.github/workflows/test-eb-hooks.yml @@ -13,6 +13,7 @@ jobs: matrix: EESSI_VERSION: - '2023.06' + - '2025.06' steps: - name: Check out software-layer repository uses: actions/checkout@b4ffde65f46336ab88eb53be808477a3936bae11 # v4.1.1 diff --git a/.github/workflows/tests_archdetect_nvidia_gpu.yml b/.github/workflows/tests_archdetect_nvidia_gpu.yml index 6effda64..759e7b31 100644 --- a/.github/workflows/tests_archdetect_nvidia_gpu.yml +++ b/.github/workflows/tests_archdetect_nvidia_gpu.yml @@ -19,6 +19,7 @@ jobs: - cc01 # non-existing GPU EESSI_VERSION: - '2023.06' + - '2025.06' fail-fast: false steps: - name: checkout diff --git a/.github/workflows/tests_eessi_extend_module.yml b/.github/workflows/tests_eessi_extend_module.yml index 7d8e9daa..4986ec0f 100644 --- a/.github/workflows/tests_eessi_extend_module.yml +++ b/.github/workflows/tests_eessi_extend_module.yml @@ -14,10 +14,11 @@ jobs: matrix: EESSI_VERSION: - '2023.06' + - '2025.06' steps: - name: Check out software-layer repository uses: actions/checkout@b4ffde65f46336ab88eb53be808477a3936bae11 # v4.1.1 - + - name: Mount EESSI CernVM-FS repository uses: eessi/github-action-eessi@v3 with: diff --git a/.github/workflows/tests_eessi_module.yml b/.github/workflows/tests_eessi_module.yml index c13b182b..1d16f817 100644 --- a/.github/workflows/tests_eessi_module.yml +++ b/.github/workflows/tests_eessi_module.yml @@ -14,10 +14,11 @@ jobs: matrix: EESSI_VERSION: - '2023.06' + - '2025.06' steps: - name: Check out software-layer repository uses: actions/checkout@b4ffde65f46336ab88eb53be808477a3936bae11 # v4.1.1 - + - name: Mount EESSI CernVM-FS pilot repository uses: cvmfs-contrib/github-action-cvmfs@55899ca74cf78ab874bdf47f5a804e47c198743c # v4.0 with: @@ -69,6 +70,7 @@ jobs: matrix: EESSI_VERSION: - '2023.06' + - '2025.06' EESSI_SOFTWARE_SUBDIR_OVERRIDE: - x86_64/amd/zen3 - x86_64/amd/zen4 @@ -80,7 +82,7 @@ jobs: steps: - name: Check out software-layer repository uses: actions/checkout@b4ffde65f46336ab88eb53be808477a3936bae11 # v4.1.1 - + - name: Mount EESSI CernVM-FS pilot repository uses: cvmfs-contrib/github-action-cvmfs@55899ca74cf78ab874bdf47f5a804e47c198743c # v4.0 with: @@ -141,9 +143,9 @@ jobs: echo "" if (diff "${moduleoutfile}" "${sourceoutfile}" > /dev/null); then echo "Test for checking env variables PASSED" - else + else echo "Test for checking env variables FAILED" >&2 - diff --unified=0 "${moduleoutfile}" "${sourceoutfile}" + diff --unified=0 "${moduleoutfile}" "${sourceoutfile}" exit 1 fi @@ -154,6 +156,7 @@ jobs: matrix: EESSI_VERSION: - '2023.06' + - '2025.06' EESSI_SOFTWARE_SUBDIR_OVERRIDE: - none - x86_64/amd/zen2 diff --git a/.github/workflows/tests_init_module.yml b/.github/workflows/tests_init_module.yml index 42bb42e9..f0694a92 100644 --- a/.github/workflows/tests_init_module.yml +++ b/.github/workflows/tests_init_module.yml @@ -15,8 +15,14 @@ jobs: matrix: EESSI_VERSION: - '2023.06' + - '2025.06' EESSI_SOFTWARE_SUBDIR_OVERRIDE: - x86_64/intel/haswell + include: + - EESSI_VERSION: '2023.06' + EXPECTED_EASYBUILD_VERSION: '5.0.0' + - EESSI_VERSION: '2025.06' + EXPECTED_EASYBUILD_VERSION: '5.1.1' steps: - name: Check out software-layer repository uses: actions/checkout@b4ffde65f46336ab88eb53be808477a3936bae11 # v4.1.1 @@ -33,7 +39,7 @@ jobs: for shell in $(ls init/lmod); do sed -i "s/__EESSI_VERSION_DEFAULT__/${{matrix.EESSI_VERSION}}/g" init/lmod/${shell} done - + - name: Clone assert.sh script run: git clone https://github.com/lehmannro/assert.sh.git @@ -45,5 +51,7 @@ jobs: - name: Run tests for available shells run: | + export EESSI_VERSION=${{matrix.EESSI_VERSION}} + export EXPECTED_EASYBUILD_VERSION=${{matrix.EXPECTED_EASYBUILD_VERSION}} .github/workflows/scripts/test_init_scripts.sh "bash" "zsh" "ksh" "fish" "csh" diff --git a/.github/workflows/tests_scripts.yml b/.github/workflows/tests_scripts.yml index 9fd6421c..7a8f5fa4 100644 --- a/.github/workflows/tests_scripts.yml +++ b/.github/workflows/tests_scripts.yml @@ -34,6 +34,7 @@ jobs: matrix: EESSI_VERSION: - '2023.06' + - '2025.06' steps: - name: checkout uses: actions/checkout@b4ffde65f46336ab88eb53be808477a3936bae11 # v4.1.1