diff options
Diffstat (limited to 'lib')
-rw-r--r-- | lib/spack/spack/modules/common.py | 2 | ||||
-rw-r--r-- | lib/spack/spack/test/cmd/env.py | 4 | ||||
-rw-r--r-- | lib/spack/spack/test/modules/lmod.py | 2 |
3 files changed, 4 insertions, 4 deletions
diff --git a/lib/spack/spack/modules/common.py b/lib/spack/spack/modules/common.py index 1e5f261578..ffd170226d 100644 --- a/lib/spack/spack/modules/common.py +++ b/lib/spack/spack/modules/common.py @@ -698,7 +698,7 @@ class BaseContext(tengine.Context): use_view = ev.default_view_name env = ev.get_env({}, 'post_env_write_hook', required=True) - view = env.views[use_view].view() + view = env.views[use_view] spec.prefix = view.get_projection_for_spec(spec) diff --git a/lib/spack/spack/test/cmd/env.py b/lib/spack/spack/test/cmd/env.py index 002bd14c0f..5aa30a9455 100644 --- a/lib/spack/spack/test/cmd/env.py +++ b/lib/spack/spack/test/cmd/env.py @@ -2504,7 +2504,7 @@ spack: install() spec = e.specs_by_hash[e.concretized_order[0]] - view_prefix = e.default_view.view().get_projection_for_spec(spec) + view_prefix = e.default_view.get_projection_for_spec(spec) modules_glob = '%s/modules/**/*' % e.path modules = glob.glob(modules_glob) assert len(modules) == 1 @@ -2539,7 +2539,7 @@ spack: install() spec = e.specs_by_hash[e.concretized_order[0]] - view_prefix = e.default_view.view().get_projection_for_spec(spec) + view_prefix = e.default_view.get_projection_for_spec(spec) modules_glob = '%s/modules/**/*' % e.path modules = glob.glob(modules_glob) assert len(modules) == 1 diff --git a/lib/spack/spack/test/modules/lmod.py b/lib/spack/spack/test/modules/lmod.py index 097aaf526f..049bddcd9a 100644 --- a/lib/spack/spack/test/modules/lmod.py +++ b/lib/spack/spack/test/modules/lmod.py @@ -346,7 +346,7 @@ class TestLmod(object): spec = spack.spec.Spec('cmake').concretized() content = modulefile_content('cmake') - expected = e.default_view.view().get_projection_for_spec(spec) + expected = e.default_view.get_projection_for_spec(spec) # Rather than parse all lines, ensure all prefixes in the content # point to the right one assert any(expected in line for line in content) |