#%Module1.0

##############################################################################
#   Modules Revision 3.0
#   Providing a flexible user environment
#
#   File:		info/%M%
#   Revision:		%I%
#   First Edition:	2017/05/22
#   Last Mod.:		%U%, %G%
#
#   Authors:		Xavier Delaruelle, xavier.delaruelle@cea.fr
#
#   Description:	Testuite modulefile
#   Command:
#   Sub-Command:	module-info
#
#   Invocation:
#   Result:	%R{
#		}R%
#   Comment:	%C{
#			Tests the 'module-info' module subcommand with bad or
#			deprecated keywords.
#		}C%
#
##############################################################################

proc ModulesDisplay { } {
    puts stderr "trace: [module-info trace]"
    puts stderr "tracepat: [module-info tracepat]"
    puts stderr "[module-info bad]"
}

proc ModulesHelp { } {
    puts stderr "trace: [module-info trace]"
    puts stderr "tracepat: [module-info tracepat]"
    puts stderr "[module-info bad]"
}

proc ModulesTest { } {
    puts stderr "trace: [module-info trace]"
    puts stderr "tracepat: [module-info tracepat]"
    puts stderr "[module-info bad]"
    return 1
}

if { [module-info mode load] } {
    puts stderr "trace: [module-info trace]"
    puts stderr "tracepat: [module-info tracepat]"
    puts stderr "[module-info bad]"
} elseif { [module-info mode whatis] } {
    module-whatis "trace: [module-info trace]"
    module-whatis "tracepat: [module-info tracepat]"
    module-whatis "[module-info bad]"
}
