summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDan Bonachea <dobonachea@lbl.gov>2021-05-18 20:40:51 -0400
committerGitHub <noreply@github.com>2021-05-18 17:40:51 -0700
commitce7516f25fe8748da8778acb110aab26a383c5f4 (patch)
tree1238aca533ed390982cfd7f4f07a8532f564ec60
parentf0d5d992e6687d062204cf6b14045cddc7bec62f (diff)
downloadspack-ce7516f25fe8748da8778acb110aab26a383c5f4.tar.gz
spack-ce7516f25fe8748da8778acb110aab26a383c5f4.tar.bz2
spack-ce7516f25fe8748da8778acb110aab26a383c5f4.tar.xz
spack-ce7516f25fe8748da8778acb110aab26a383c5f4.zip
upcxx: Add support for stand-alone post-install tests (#23714)
This uses the existing script which is always installed for this purpose in modern versions.
-rw-r--r--var/spack/repos/builtin/packages/upcxx/package.py12
1 files changed, 12 insertions, 0 deletions
diff --git a/var/spack/repos/builtin/packages/upcxx/package.py b/var/spack/repos/builtin/packages/upcxx/package.py
index 3552ec8380..47ad7defca 100644
--- a/var/spack/repos/builtin/packages/upcxx/package.py
+++ b/var/spack/repos/builtin/packages/upcxx/package.py
@@ -175,3 +175,15 @@ class Upcxx(Package):
if 'cross=none' in self.spec:
make('run-tests', 'NETWORKS=smp') # runs tests for smp backend
make('tests-clean') # cleanup
+
+ def test(self):
+ if self.spec.version <= Version('2019.9.0'):
+ spack.main.send_warning_to_tty(
+ "post-install tests not supported in UPC++ version " +
+ self.spec.version.string + " -- SKIPPED")
+ else: # run post-install smoke test:
+ test_install = join_path(self.prefix.bin, 'test-upcxx-install.sh')
+ self.run_test(test_install, expected=['SUCCESS'], status=0,
+ installed=True,
+ purpose='Checking UPC++ compile+link ' +
+ 'for all installed backends')