From 7bda4ef871a206c39b21e2c32fa429cb2d542592 Mon Sep 17 00:00:00 2001 From: Matthew Cawood Date: Mon, 13 Jan 2025 13:49:37 -0600 Subject: [PATCH] reverted unload tests --- .../mf/Compiler/gcc/4.7/mpich2/1.5.2.lua | 18 +++++++++++++++- .../mf/Compiler/intel/13.0/mpich2/1.5.2.lua | 18 +++++++++++++++- rt/unload/mf/Core/B/2.0.lua | 2 +- rt/unload/mf/Core/C/1.0.lua | 21 ------------------- rt/unload/mf/Core/D/1.0.lua | 4 ---- rt/unload/mf/Core/E/1.0.lua | 2 -- rt/unload/mf/Core/F/1.0.lua | 2 -- .../mf/MPI/gcc/4.7/mpich2/1.5/petsc/3.2.lua | 2 +- .../MPI/intel/13.0/mpich2/1.5/petsc/3.2.lua | 2 +- rt/unload/unload.tdesc | 9 -------- 10 files changed, 37 insertions(+), 43 deletions(-) mode change 120000 => 100644 rt/unload/mf/Compiler/gcc/4.7/mpich2/1.5.2.lua mode change 120000 => 100644 rt/unload/mf/Compiler/intel/13.0/mpich2/1.5.2.lua delete mode 100644 rt/unload/mf/Core/C/1.0.lua delete mode 100644 rt/unload/mf/Core/D/1.0.lua delete mode 100644 rt/unload/mf/Core/E/1.0.lua delete mode 100644 rt/unload/mf/Core/F/1.0.lua mode change 120000 => 100644 rt/unload/mf/MPI/gcc/4.7/mpich2/1.5/petsc/3.2.lua mode change 120000 => 100644 rt/unload/mf/MPI/intel/13.0/mpich2/1.5/petsc/3.2.lua diff --git a/rt/unload/mf/Compiler/gcc/4.7/mpich2/1.5.2.lua b/rt/unload/mf/Compiler/gcc/4.7/mpich2/1.5.2.lua deleted file mode 120000 index 66fbed5fe..000000000 --- a/rt/unload/mf/Compiler/gcc/4.7/mpich2/1.5.2.lua +++ /dev/null @@ -1 +0,0 @@ -../../../.base/mpich2/1.5.2.lua \ No newline at end of file diff --git a/rt/unload/mf/Compiler/gcc/4.7/mpich2/1.5.2.lua b/rt/unload/mf/Compiler/gcc/4.7/mpich2/1.5.2.lua new file mode 100644 index 000000000..98a5daa17 --- /dev/null +++ b/rt/unload/mf/Compiler/gcc/4.7/mpich2/1.5.2.lua @@ -0,0 +1,17 @@ +-- -*- lua -*- +local pkgName = "mpich2" +local fn = myFileName():gsub("%.lua$","") +local fullVersion = barefilename(fn) +local pkgVersion = fullVersion:match("([0-9]+%.[0-9]+)%.?") +local pkgNameFullV = pathJoin(pkgName,fullVersion) +local pkgNameVer = pathJoin(pkgName,pkgVersion) +local hierA = hierarchyA(pkgNameFullV,1) +local compiler_dir = hierA[1] +local pkgRoot = "/unknown/apps" +local mdir = pathJoin(os.getenv('MODULEPATH_ROOT'), "MPI",compiler_dir,pkgNameVer) +compiler_dir = compiler_dir:gsub("/","-"):gsub("%.","_") +local mpihome = pathJoin(pkgRoot, compiler_dir, pkgNameFullV) + +family("MPI") +prepend_path('MODULEPATH', mdir) + diff --git a/rt/unload/mf/Compiler/intel/13.0/mpich2/1.5.2.lua b/rt/unload/mf/Compiler/intel/13.0/mpich2/1.5.2.lua deleted file mode 120000 index 66fbed5fe..000000000 --- a/rt/unload/mf/Compiler/intel/13.0/mpich2/1.5.2.lua +++ /dev/null @@ -1 +0,0 @@ -../../../.base/mpich2/1.5.2.lua \ No newline at end of file diff --git a/rt/unload/mf/Compiler/intel/13.0/mpich2/1.5.2.lua b/rt/unload/mf/Compiler/intel/13.0/mpich2/1.5.2.lua new file mode 100644 index 000000000..98a5daa17 --- /dev/null +++ b/rt/unload/mf/Compiler/intel/13.0/mpich2/1.5.2.lua @@ -0,0 +1,17 @@ +-- -*- lua -*- +local pkgName = "mpich2" +local fn = myFileName():gsub("%.lua$","") +local fullVersion = barefilename(fn) +local pkgVersion = fullVersion:match("([0-9]+%.[0-9]+)%.?") +local pkgNameFullV = pathJoin(pkgName,fullVersion) +local pkgNameVer = pathJoin(pkgName,pkgVersion) +local hierA = hierarchyA(pkgNameFullV,1) +local compiler_dir = hierA[1] +local pkgRoot = "/unknown/apps" +local mdir = pathJoin(os.getenv('MODULEPATH_ROOT'), "MPI",compiler_dir,pkgNameVer) +compiler_dir = compiler_dir:gsub("/","-"):gsub("%.","_") +local mpihome = pathJoin(pkgRoot, compiler_dir, pkgNameFullV) + +family("MPI") +prepend_path('MODULEPATH', mdir) + diff --git a/rt/unload/mf/Core/B/2.0.lua b/rt/unload/mf/Core/B/2.0.lua index 257e384c7..f8a8ef833 100644 --- a/rt/unload/mf/Core/B/2.0.lua +++ b/rt/unload/mf/Core/B/2.0.lua @@ -1,5 +1,5 @@ setenv("TOTO","set_in_B/2.0") if (mode() == "unload") then - LmodError("Sucessfully raised mode error in unload of B/2.0") + LmodError("Error in unload of B/2.0") end diff --git a/rt/unload/mf/Core/C/1.0.lua b/rt/unload/mf/Core/C/1.0.lua deleted file mode 100644 index c22a6108d..000000000 --- a/rt/unload/mf/Core/C/1.0.lua +++ /dev/null @@ -1,21 +0,0 @@ -setenv{"FOO", "BAR", mode={"load"}} -setenv{"A", "B", mode={"unload"}} -pushenv{"STACK_VAR", "load_value", mode={"load"}} -pushenv{"STACK_VAR", "unload_value", mode={"unload"}} - --- Path operation tests -prepend_path{"PATH_TEST", "/first", mode={"load"}} -prepend_path{"PATH_TEST", "/unload_first", mode={"unload"}} - -append_path{"PATH_TEST", "/last", mode={"load"}} -append_path{"PATH_TEST", "/unload_last", mode={"unload"}} - --- Test remove during specific modes ---remove_path{"PATH_TEST", "/to_remove", mode={"unload"}} - - ---setenv{"AA", "X", mode={"load", "unload"}} ---prepend_path{"FOO", "BAR", mode={"unload", "load"}} ---append_path{"X", "Y", mode={"unload"}} ---load{"D", mode={"unload"}} ---try_load{"J", mode={"unload"}} diff --git a/rt/unload/mf/Core/D/1.0.lua b/rt/unload/mf/Core/D/1.0.lua deleted file mode 100644 index d502289cf..000000000 --- a/rt/unload/mf/Core/D/1.0.lua +++ /dev/null @@ -1,4 +0,0 @@ --- Test module D -load{"E", mode={"load"}} --- load{"A", "B", "C", mode="unload"} -setenv("D_LOADED", "yes") \ No newline at end of file diff --git a/rt/unload/mf/Core/E/1.0.lua b/rt/unload/mf/Core/E/1.0.lua deleted file mode 100644 index 505f80f21..000000000 --- a/rt/unload/mf/Core/E/1.0.lua +++ /dev/null @@ -1,2 +0,0 @@ --- Test module E -setenv("E_LOADED", "yes") \ No newline at end of file diff --git a/rt/unload/mf/Core/F/1.0.lua b/rt/unload/mf/Core/F/1.0.lua deleted file mode 100644 index 1b23c01f5..000000000 --- a/rt/unload/mf/Core/F/1.0.lua +++ /dev/null @@ -1,2 +0,0 @@ --- Test module F -setenv("F_LOADED", "yes") \ No newline at end of file diff --git a/rt/unload/mf/MPI/gcc/4.7/mpich2/1.5/petsc/3.2.lua b/rt/unload/mf/MPI/gcc/4.7/mpich2/1.5/petsc/3.2.lua deleted file mode 120000 index d3f3c976e..000000000 --- a/rt/unload/mf/MPI/gcc/4.7/mpich2/1.5/petsc/3.2.lua +++ /dev/null @@ -1 +0,0 @@ -../../../../../.base/petsc/3.2.lua \ No newline at end of file diff --git a/rt/unload/mf/MPI/gcc/4.7/mpich2/1.5/petsc/3.2.lua b/rt/unload/mf/MPI/gcc/4.7/mpich2/1.5/petsc/3.2.lua new file mode 100644 index 000000000..b79f3bb4c --- /dev/null +++ b/rt/unload/mf/MPI/gcc/4.7/mpich2/1.5/petsc/3.2.lua @@ -0,0 +1 @@ +setenv("PETSC_VERSION","3.2") diff --git a/rt/unload/mf/MPI/intel/13.0/mpich2/1.5/petsc/3.2.lua b/rt/unload/mf/MPI/intel/13.0/mpich2/1.5/petsc/3.2.lua deleted file mode 120000 index d3f3c976e..000000000 --- a/rt/unload/mf/MPI/intel/13.0/mpich2/1.5/petsc/3.2.lua +++ /dev/null @@ -1 +0,0 @@ -../../../../../.base/petsc/3.2.lua \ No newline at end of file diff --git a/rt/unload/mf/MPI/intel/13.0/mpich2/1.5/petsc/3.2.lua b/rt/unload/mf/MPI/intel/13.0/mpich2/1.5/petsc/3.2.lua new file mode 100644 index 000000000..b79f3bb4c --- /dev/null +++ b/rt/unload/mf/MPI/intel/13.0/mpich2/1.5/petsc/3.2.lua @@ -0,0 +1 @@ +setenv("PETSC_VERSION","3.2") diff --git a/rt/unload/unload.tdesc b/rt/unload/unload.tdesc index 3dbef32d2..817b69e66 100644 --- a/rt/unload/unload.tdesc +++ b/rt/unload/unload.tdesc @@ -38,15 +38,6 @@ testdescript = { runLmod unload intel # 7 runLmod load B # 8 runLmod unload B # 9 - runLmod load C # 10 - runLmod unload C # 11 - - # Test mode-specific load functionality - runLmod load F # 12 (Load F first for unload test) - runLmod load D # 13 (Should load E, not affect F) - runLmod list # 14 (Should show D, E, and F loaded) - runLmod unload D # 15 (Should unload F, keep E) - runLmod list # 16 (Should show only E loaded) HOME=$ORIG_HOME