Skip to content

Commit

Permalink
Issue #690: adding tests to load hidden modules (.a/.1, .b/1.0, c/.1)
Browse files Browse the repository at this point in the history
  • Loading branch information
Robert McLay committed Aug 10, 2024
1 parent a046736 commit 7dba4cb
Show file tree
Hide file tree
Showing 6 changed files with 75 additions and 20 deletions.
28 changes: 20 additions & 8 deletions rt/hidden/err.txt
Original file line number Diff line number Diff line change
Expand Up @@ -2,14 +2,14 @@
step 1
lua ProjectDIR/src/lmod.in.lua shell --regression_testing --version
===========================
Modules based on Lua: Version 8.7.44 2024-07-11 16:39 -06:00
Modules based on Lua: Version 8.7.47 2024-07-22 10:04 -04:00
by Robert McLay [email protected]
===========================
step 2
lua ProjectDIR/src/lmod.in.lua shell --regression_testing --show_hidden avail
===========================
ProjectDIR/rt/hidden/mf
.system (H,S) lmod
.a/.1 (H) .b/1.0 (H) .system (H,S) c/.1 (H) lmod
Where:
H: Hidden Module
S: Module is Sticky, requires --force to unload or purge
Expand All @@ -24,22 +24,34 @@ lua ProjectDIR/src/lmod.in.lua shell --regression_testing load .system
===========================
===========================
step 4
lua ProjectDIR/src/lmod.in.lua shell --regression_testing load .a/.1
===========================
===========================
step 5
lua ProjectDIR/src/lmod.in.lua shell --regression_testing load .b/1.0
===========================
===========================
step 6
lua ProjectDIR/src/lmod.in.lua shell --regression_testing load c/.1
===========================
===========================
step 7
lua ProjectDIR/src/lmod.in.lua shell --regression_testing list
===========================
Currently Loaded Modules:
1) .system (H,S)
1) .system (H,S) 2) .a/.1 (H) 3) .b/1.0 (H) 4) c/.1 (H)
Where:
H: Hidden Module
S: Module is Sticky, requires --force to unload or purge
===========================
step 5
step 8
lua ProjectDIR/src/lmod.in.lua shell --regression_testing purge
===========================
The following modules were not unloaded:
(Use "module --force purge" to unload all):
1) .system
===========================
step 6
step 9
lua ProjectDIR/src/lmod.in.lua shell --regression_testing --show_hidden av
===========================
ProjectDIR/rt/hidden/mf2/top
Expand All @@ -56,15 +68,15 @@ If the avail list is too long consider trying:
Use "module spider" to find all possible modules and extensions.
Use "module keyword key1 key2 ..." to search for all possible modules matching any of the "keys".
===========================
step 7
step 10
lua ProjectDIR/src/lmod.in.lua shell --regression_testing load B
===========================
===========================
step 8
step 11
lua ProjectDIR/src/lmod.in.lua shell --regression_testing load A
===========================
===========================
step 9
step 12
lua ProjectDIR/src/lmod.in.lua shell --regression_testing list
===========================
Currently Loaded Modules:
Expand Down
15 changes: 9 additions & 6 deletions rt/hidden/hidden.tdesc
Original file line number Diff line number Diff line change
Expand Up @@ -27,16 +27,19 @@ testdescript = {
runLmod --show_hidden avail # 2
runLmod load .system # 3
runLmod list # 4
runLmod load .a/.1 # 4
runLmod load .b/1.0 # 5
runLmod load c/.1 # 6
runLmod list # 7
runLmod purge # 5
runLmod purge # 8
unsetMT
export MODULEPATH=$(testDir)/mf2/top:$(testDir)/mf2/bottom
export LMOD_TMOD_FIND_FIRST=1
runLmod --show_hidden av # 6
runLmod load B # 7
runLmod load A # 8
runLmod list # 9
runLmod --show_hidden av # 9
runLmod load B #10
runLmod load A #11
runLmod list #12
HOME=$ORIG_HOME
cat _stdout.[0-9][0-9][0-9] > _stdout.orig
Expand Down
Empty file added rt/hidden/mf/.a/.1.lua
Empty file.
Empty file added rt/hidden/mf/.b/1.0.lua
Empty file.
Empty file added rt/hidden/mf/c/.1.lua
Empty file.
52 changes: 46 additions & 6 deletions rt/hidden/out.txt
Original file line number Diff line number Diff line change
Expand Up @@ -26,22 +26,62 @@ _ModuleTable_='_ModuleTable_={MTversion=3,depthT={},family={},mT={[".system"]={f
export _ModuleTable_;
===========================
step 4
lua ProjectDIR/src/lmod.in.lua shell --regression_testing list
lua ProjectDIR/src/lmod.in.lua shell --regression_testing load .a/.1
===========================
LOADEDMODULES=.system:.a/.1;
export LOADEDMODULES;
MODULEPATH=ProjectDIR/rt/hidden/mf;
export MODULEPATH;
_ModuleTable_='_ModuleTable_={MTversion=3,depthT={},family={},mT={[".system"]={fn="ProjectDIR/rt/hidden/mf/.system.lua",fullName=".system",loadOrder=1,propT={lmod={sticky=1,},},stackDepth=0,status="active",userName=".system",wV="M.*zfinal",},},mpathA={"ProjectDIR/rt/hidden/mf",},systemBaseMPATH="ProjectDIR/rt/hidden/mf",}';
_LMFILES_=ProjectDIR/rt/hidden/mf/.system.lua:ProjectDIR/rt/hidden/mf/.a/.1.lua;
export _LMFILES_;
_ModuleTable_='_ModuleTable_={MTversion=3,depthT={},family={},mT={[".a"]={fn="ProjectDIR/rt/hidden/mf/.a/.1.lua",fullName=".a/.1",loadOrder=2,propT={},stackDepth=0,status="active",userName=".a/.1",wV="000000000.000000001.*zfinal",},[".system"]={fn="ProjectDIR/rt/hidden/mf/.system.lua",fullName=".system",loadOrder=1,propT={lmod={sticky=1,},},stackDepth=0,status="active",userName=".system",wV="M.*zfinal",},},mpathA={"ProjectDIR/rt/hidden/mf",},systemBaseMPATH="ProjectDIR/rt/hidden/mf",}';
export _ModuleTable_;
===========================
step 5
lua ProjectDIR/src/lmod.in.lua shell --regression_testing load .b/1.0
===========================
LOADEDMODULES=.system:.a/.1:.b/1.0;
export LOADEDMODULES;
MODULEPATH=ProjectDIR/rt/hidden/mf;
export MODULEPATH;
_LMFILES_=ProjectDIR/rt/hidden/mf/.system.lua:ProjectDIR/rt/hidden/mf/.a/.1.lua:ProjectDIR/rt/hidden/mf/.b/1.0.lua;
export _LMFILES_;
_ModuleTable_='_ModuleTable_={MTversion=3,depthT={},family={},mT={[".a"]={fn="ProjectDIR/rt/hidden/mf/.a/.1.lua",fullName=".a/.1",loadOrder=2,propT={},stackDepth=0,status="active",userName=".a/.1",wV="000000000.000000001.*zfinal",},[".b"]={fn="ProjectDIR/rt/hidden/mf/.b/1.0.lua",fullName=".b/1.0",loadOrder=3,propT={},stackDepth=0,status="active",userName=".b/1.0",wV="000000001.*zfinal",},[".system"]={fn="ProjectDIR/rt/hidden/mf/.system.lua",fullName=".system",loadOrder=1,propT={lmod={sticky=1,},},stackDepth=0,status="active",userName=".system",wV="M.*zfinal",},},mpathA={"ProjectDIR/rt/hidden/mf",},systemBaseMPATH="ProjectDIR/rt/hidden/mf",}';
export _ModuleTable_;
===========================
step 6
lua ProjectDIR/src/lmod.in.lua shell --regression_testing load c/.1
===========================
LOADEDMODULES=.system:.a/.1:.b/1.0:c/.1;
export LOADEDMODULES;
MODULEPATH=ProjectDIR/rt/hidden/mf;
export MODULEPATH;
_LMFILES_=ProjectDIR/rt/hidden/mf/.system.lua:ProjectDIR/rt/hidden/mf/.a/.1.lua:ProjectDIR/rt/hidden/mf/.b/1.0.lua:ProjectDIR/rt/hidden/mf/c/.1.lua;
export _LMFILES_;
_ModuleTable_='_ModuleTable_={MTversion=3,depthT={},family={},mT={[".a"]={fn="ProjectDIR/rt/hidden/mf/.a/.1.lua",fullName=".a/.1",loadOrder=2,propT={},stackDepth=0,status="active",userName=".a/.1",wV="000000000.000000001.*zfinal",},[".b"]={fn="ProjectDIR/rt/hidden/mf/.b/1.0.lua",fullName=".b/1.0",loadOrder=3,propT={},stackDepth=0,status="active",userName=".b/1.0",wV="000000001.*zfinal",},[".system"]={fn="ProjectDIR/rt/hidden/mf/.system.lua",fullName=".system",loadOrder=1,propT={lmod={sticky=1,},},stackDepth=0,status="active",userName=".system",wV="M.*zfinal",},c={fn="ProjectDIR/rt/hidden/mf/c/.1.lua",fullName="c/.1",loadOrder=4,propT={},stackDepth=0,status="active",userName="c/.1",wV="000000000.000000001.*zfinal",},},mpathA={"ProjectDIR/rt/hidden/mf",},systemBaseMPATH="ProjectDIR/rt/hidden/mf",}';
export _ModuleTable_;
===========================
step 7
lua ProjectDIR/src/lmod.in.lua shell --regression_testing list
===========================
MODULEPATH=ProjectDIR/rt/hidden/mf;
export MODULEPATH;
_ModuleTable_='_ModuleTable_={MTversion=3,depthT={},family={},mT={[".a"]={fn="ProjectDIR/rt/hidden/mf/.a/.1.lua",fullName=".a/.1",loadOrder=2,propT={},stackDepth=0,status="active",userName=".a/.1",wV="000000000.000000001.*zfinal",},[".b"]={fn="ProjectDIR/rt/hidden/mf/.b/1.0.lua",fullName=".b/1.0",loadOrder=3,propT={},stackDepth=0,status="active",userName=".b/1.0",wV="000000001.*zfinal",},[".system"]={fn="ProjectDIR/rt/hidden/mf/.system.lua",fullName=".system",loadOrder=1,propT={lmod={sticky=1,},},stackDepth=0,status="active",userName=".system",wV="M.*zfinal",},c={fn="ProjectDIR/rt/hidden/mf/c/.1.lua",fullName="c/.1",loadOrder=4,propT={},stackDepth=0,status="active",userName="c/.1",wV="000000000.000000001.*zfinal",},},mpathA={"ProjectDIR/rt/hidden/mf",},systemBaseMPATH="ProjectDIR/rt/hidden/mf",}';
export _ModuleTable_;
===========================
step 8
lua ProjectDIR/src/lmod.in.lua shell --regression_testing purge
===========================
LOADEDMODULES=.system;
export LOADEDMODULES;
MODULEPATH=ProjectDIR/rt/hidden/mf;
export MODULEPATH;
_LMFILES_=ProjectDIR/rt/hidden/mf/.system.lua;
export _LMFILES_;
_ModuleTable_='_ModuleTable_={MTversion=3,depthT={},family={},mT={[".system"]={fn="ProjectDIR/rt/hidden/mf/.system.lua",fullName=".system",loadOrder=1,propT={lmod={sticky=1,},},stackDepth=0,status="active",userName=".system",wV="M.*zfinal",},},mpathA={"ProjectDIR/rt/hidden/mf",},systemBaseMPATH="ProjectDIR/rt/hidden/mf",}';
export _ModuleTable_;
===========================
step 6
step 9
lua ProjectDIR/src/lmod.in.lua shell --regression_testing --show_hidden av
===========================
unset LOADEDMODULES;
Expand All @@ -53,7 +93,7 @@ unset _LMFILES_;
_ModuleTable_='_ModuleTable_={MTversion=3,depthT={},family={},mT={},mpathA={"ProjectDIR/rt/hidden/mf2/top","ProjectDIR/rt/hidden/mf2/bottom",},systemBaseMPATH="ProjectDIR/rt/hidden/mf2/top:ProjectDIR/rt/hidden/mf2/bottom",}';
export _ModuleTable_;
===========================
step 7
step 10
lua ProjectDIR/src/lmod.in.lua shell --regression_testing load B
===========================
B=9.8.7;
Expand All @@ -67,7 +107,7 @@ export _LMFILES_;
_ModuleTable_='_ModuleTable_={MTversion=3,depthT={},family={},mT={B={fn="ProjectDIR/rt/hidden/mf2/bottom/B/9.8.7.lua",fullName="B/9.8.7",loadOrder=1,propT={},stackDepth=0,status="active",userName="B",wV="000000009.000000008.000000007.*zfinal",},},mpathA={"ProjectDIR/rt/hidden/mf2/top","ProjectDIR/rt/hidden/mf2/bottom",},systemBaseMPATH="ProjectDIR/rt/hidden/mf2/top:ProjectDIR/rt/hidden/mf2/bottom",}';
export _ModuleTable_;
===========================
step 8
step 11
lua ProjectDIR/src/lmod.in.lua shell --regression_testing load A
===========================
A=1.0;
Expand All @@ -81,7 +121,7 @@ export _LMFILES_;
_ModuleTable_='_ModuleTable_={MTversion=3,depthT={},family={},mT={A={fn="ProjectDIR/rt/hidden/mf2/top/A/1.0.lua",fullName="A/1.0",loadOrder=2,propT={},stackDepth=0,status="active",userName="A",wV="000000001.*zfinal",},B={fn="ProjectDIR/rt/hidden/mf2/bottom/B/9.8.7.lua",fullName="B/9.8.7",loadOrder=1,propT={},stackDepth=0,status="active",userName="B",wV="000000009.000000008.000000007.*zfinal",},},mpathA={"ProjectDIR/rt/hidden/mf2/top","ProjectDIR/rt/hidden/mf2/bottom",},systemBaseMPATH="ProjectDIR/rt/hidden/mf2/top:ProjectDIR/rt/hidden/mf2/bottom",}';
export _ModuleTable_;
===========================
step 9
step 12
lua ProjectDIR/src/lmod.in.lua shell --regression_testing list
===========================
MODULEPATH=ProjectDIR/rt/hidden/mf2/top:ProjectDIR/rt/hidden/mf2/bottom;
Expand Down

0 comments on commit 7dba4cb

Please sign in to comment.