fix test that held reference to abstract spec

This commit is contained in:
Harmen Stoppels 2024-12-09 09:53:50 +01:00
parent 3827ebb592
commit e995d0543e

View File

@ -688,12 +688,11 @@ def test_str(self) -> None:
def test_concrete(self, mock_packages, config) -> None: def test_concrete(self, mock_packages, config) -> None:
spec = Spec("pkg-a") spec = Spec("pkg-a")
vm = VariantMap(spec) assert not VariantMap(spec).concrete
assert not vm.concrete
# concrete if associated spec is concrete # concrete if associated spec is concrete
spec = spack.concretize.concretized(spec) spec = spack.concretize.concretized(spec)
assert vm.concrete assert VariantMap(spec).concrete
# concrete if all variants are present (even if spec not concrete) # concrete if all variants are present (even if spec not concrete)
spec._mark_concrete(False) spec._mark_concrete(False)