Remove support for generating dotkit files (#11986)

Dotkit is being used only at a few sites and has been deprecated on new
machines. This commit removes all the code that provide support for the
generation of dotkit module files.

A new validator named "deprecatedProperties" has been added to the
jsonschema validators. It permits to prompt a warning message or exit
with an error if a property that has been marked as deprecated is
encountered.

* Removed references to dotkit in the docs
* Removed references to dotkit in setup-env-test.sh
* Added a unit test for the 'deprecatedProperties' schema validator
This commit is contained in:
Massimiliano Culpo
2019-10-03 07:15:01 +02:00
committed by Todd Gamblin
parent b11984767b
commit 76b9c56110
34 changed files with 121 additions and 426 deletions

View File

@@ -167,7 +167,7 @@ is_not_set() {
# -----------------------------------------------------------------------
# Instead of invoking the module/use/dotkit commands, we print the
# Instead of invoking the module commands, we print the
# arguments that Spack invokes the command with, so we can check that
# Spack passes the expected arguments in the tests below.
#
@@ -177,14 +177,6 @@ module() {
echo module "$@"
}
use() {
echo use "$@"
}
unuse() {
echo unuse "$@"
}
# -----------------------------------------------------------------------
# Setup test environment and do some preliminary checks
# -----------------------------------------------------------------------
@@ -219,11 +211,9 @@ echo "Creating a mock package installation"
spack -m install --fake a
a_install=$(spack location -i a)
a_module=$(spack -m module tcl find a)
a_dotkit=$(spack -m module dotkit find a)
b_install=$(spack location -i b)
b_module=$(spack -m module tcl find b)
b_dotkit=$(spack -m module dotkit find b)
# create a test environment for tesitng environment commands
echo "Creating a mock environment"
@@ -304,26 +294,6 @@ contains "usage: spack unload " spack -m unload -h
contains "usage: spack unload " spack -m unload -h d
contains "usage: spack unload " spack -m unload --help
title 'Testing `spack use`'
contains "use $b_dotkit" spack -m use b
fails spack -m use -l
contains "use -l --arg $b_dotkit" spack -m use -l --arg b
contains "use $b_dotkit $a_dotkit" spack -m use -r a
contains "use $b_dotkit $a_dotkit" spack -m use --dependencies a
fails spack -m use d
contains "usage: spack use " spack -m use -h
contains "usage: spack use " spack -m use -h d
contains "usage: spack use " spack -m use --help
title 'Testing `spack unuse`'
contains "unuse $b_dotkit" spack -m unuse b
fails spack -m unuse -l
contains "unuse -l --arg $b_dotkit" spack -m unuse -l --arg b
fails spack -m unuse d
contains "usage: spack unuse " spack -m unuse -h
contains "usage: spack unuse " spack -m unuse -h d
contains "usage: spack unuse " spack -m unuse --help
title 'Testing `spack env`'
contains "usage: spack env " spack env -h
contains "usage: spack env " spack env --help