1############################################################################## 2# Modules Revision 3.0 3# Providing a flexible user environment 4# 5# File: modules.50-cmds/%M% 6# Revision: %I% 7# First Edition: 1995/12/06 8# Last Mod.: %U%, %G% 9# 10# Authors: Jens Hamisch, Jens.Hamisch@Strawberry.COM 11# 12# Description: Testuite testsequence 13# Command: load 14# Modulefiles: conflict/module, trace/all_on, trace/all_off 15# Sub-Command: 16# 17# Comment: %C{ 18# Tests the 'conflict' command using a category 19# module name. This tests the reactions of modulecmd 20# if the conflicting module is not load or if 21# some module of the conflicting category is load. 22# }C% 23# 24############################################################################## 25 26# ensure auto symbolic versions are not set for these tests 27setenv_var MODULES_ADVANCED_VERSION_SPEC 0 28 29# 30# Variables. This test forces a module load command. It will result in the 31# environment variables "_LMFILES_", "LOADEDMODULES" and "testsuite" to 32# be set up 33# 34 35set module "conflict/module" 36set modulefile "$modpath/$module" 37 38set module_tron "trace/all_on" 39set modulefile_tron "$modpath/$module_tron" 40 41set module_troff "trace/all_off" 42set modulefile_troff "$modpath/$module_troff" 43 44# 45# Error messages 46# 47 48set err_tron [msg_load $module_tron "$warn_msgs: 'module-trace' command not implemented"] 49append err_tron \n\n[msg_load $module [err_conlo trace]] 50set err_troff [msg_load $module [err_conlo trace]] 51 52# 53# The tests 54# 55 56lappend ans [list setpath _LMFILES_ $modulefile_tron] 57lappend ans [list setpath LOADEDMODULES $module_tron] 58lappend ans [list ERR] 59testouterr_cmd "ALL" "load $module_tron $module" $ans "$err_tron" 60 61set ans [list] 62lappend ans [list setpath _LMFILES_ $modulefile_troff] 63lappend ans [list setpath LOADEDMODULES $module_troff] 64lappend ans [list ERR] 65testouterr_cmd "ALL" "load $module_troff $module" $ans "$err_troff" 66 67set ans [list] 68lappend ans [list set testsuite yes] 69lappend ans [list setpath LOADEDMODULES $module] 70lappend ans [list setpath _LMFILES_ $modulefile] 71lappend ans [list setpath MODULES_LMCONFLICT "$module&trace"] 72test_cmd "ALL" "load $module" $ans 73 74# 75# Cleanup 76# 77 78unset err_troff 79unset err_tron 80 81unset ans 82unsetenv_var MODULES_ADVANCED_VERSION_SPEC 83 84unset modulefile 85unset module 86unset modulefile_tron 87unset module_tron 88unset modulefile_troff 89unset module_troff 90