Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

netcdf-{c,fortran}: run tests on run_tests, not run_after(install) #526

Merged
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
9 changes: 6 additions & 3 deletions var/spack/repos/builtin/packages/netcdf-c/package.py
Original file line number Diff line number Diff line change
Expand Up @@ -561,8 +561,11 @@ def configure_args(self):

# It looks like the issues with running the tests in parallel were fixed around version 4.6.0
# (see https://github.com/Unidata/netcdf-c/commit/812c2fd4d108cca927582c0d84049c0f271bb9e0):
@when("@:4.5.0")
@run_after("install")
def check(self):
def run_checks(self):
# h5_test fails when run in parallel
make("check", parallel=False)
if self.pkg.run_tests:
make("check", parallel=self.spec.satisfies("@4.6:"))

def check(self):
pass
6 changes: 5 additions & 1 deletion var/spack/repos/builtin/packages/netcdf-fortran/package.py
Original file line number Diff line number Diff line change
Expand Up @@ -158,9 +158,13 @@ def configure_args(self):
return config_args

@run_after("install")
def check(self):
@on_package_attributes(run_tests=True)
def run_checks(self):
make("check", parallel=self.spec.satisfies("@4.5:"))

def check(self):
pass

@run_after("install")
def cray_module_filenames(self):
# Cray compiler searches for module files with uppercase names by
Expand Down
Loading