diff options
Diffstat (limited to 'lib/spack/spack/test/cmd/find.py')
-rw-r--r-- | lib/spack/spack/test/cmd/find.py | 16 |
1 files changed, 16 insertions, 0 deletions
diff --git a/lib/spack/spack/test/cmd/find.py b/lib/spack/spack/test/cmd/find.py index 45b065fce9..fe29d12d59 100644 --- a/lib/spack/spack/test/cmd/find.py +++ b/lib/spack/spack/test/cmd/find.py @@ -12,9 +12,12 @@ import spack.cmd.find from spack.main import SpackCommand from spack.spec import Spec from spack.util.pattern import Bunch +import spack.environment as ev find = SpackCommand('find') +env = SpackCommand('env') +install = SpackCommand('install') base32_alphabet = 'abcdefghijklmnopqrstuvwxyz234567' @@ -302,3 +305,16 @@ def test_find_no_sections(database, config): def test_find_command_basic_usage(database): output = find() assert 'mpileaks' in output + + +@pytest.mark.regression('9875') +def test_find_prefix_in_env(mutable_mock_env_path, install_mockery, mock_fetch, + mock_packages, mock_archive, config): + """Test `find` formats requiring concrete specs work in environments.""" + env('create', 'test') + with ev.read('test'): + install('mpileaks') + find('-p') + find('-l') + find('-L') + # Would throw error on regression |