From f4bda74b308fcb17f00fcc132dee042d79c5e9cc Mon Sep 17 00:00:00 2001 From: Denis Davydov Date: Fri, 11 Jan 2019 19:07:28 +0100 Subject: dealii: fix concretization of xsdk package (#10288) * dealii: fix concretization of xsdk package * tests: add concretization tests for deal.II and xSDK, which are often broken due to limitations in the concretizer * use pytest.mark.parametrize --- lib/spack/spack/test/concretize.py | 11 +++++++++++ var/spack/repos/builtin/packages/dealii/package.py | 4 ++-- 2 files changed, 13 insertions(+), 2 deletions(-) diff --git a/lib/spack/spack/test/concretize.py b/lib/spack/spack/test/concretize.py index 8eb759169d..92a389992c 100644 --- a/lib/spack/spack/test/concretize.py +++ b/lib/spack/spack/test/concretize.py @@ -224,6 +224,17 @@ class TestConcretize(object): s.concretize() assert s['mpi'].version == ver('1.10.3') + @pytest.mark.parametrize("spec,version", [ + ('dealii', 'develop'), + ('xsdk', '0.4.0'), + ]) + def concretize_difficult_packages(self, a, b): + """Test a couple of large packages that are often broken due + to current limitations in the concretizer""" + s = Spec(a + '@' + b) + s.concretize() + assert s[a].version == ver(b) + def test_concretize_two_virtuals(self): """Test a package with multiple virtual dependencies.""" diff --git a/var/spack/repos/builtin/packages/dealii/package.py b/var/spack/repos/builtin/packages/dealii/package.py index 7705d0cccf..f5e00a819d 100644 --- a/var/spack/repos/builtin/packages/dealii/package.py +++ b/var/spack/repos/builtin/packages/dealii/package.py @@ -127,8 +127,8 @@ class Dealii(CMakePackage, CudaPackage): depends_on('cmake@:3.9.99', when='@:8.99') # FIXME: concretizer bug. The two lines mimic what comes from PETSc # but we should not need it - depends_on('metis@5:+int64+real64', when='+metis+int64') - depends_on('metis@5:~int64+real64', when='+metis~int64') + depends_on('metis@5:+int64', when='+metis+int64') + depends_on('metis@5:~int64', when='+metis~int64') depends_on('muparser', when='+muparser') depends_on('nanoflann', when='@9.0:+nanoflann') depends_on('netcdf+mpi', when='+netcdf+mpi') -- cgit v1.2.3-60-g2f50