|
1 | 1 | import os |
2 | 2 |
|
| 3 | +import reframe as rfm |
3 | 4 | import reframe.utility.sanity as sn |
4 | | -from reframe.core.pipeline import RunOnlyRegressionTest |
5 | 5 |
|
6 | 6 |
|
7 | | -class LibSciAccSymLinkTest(RunOnlyRegressionTest): |
8 | | - def __init__(self, lib_name, **kwargs): |
9 | | - super().__init__(lib_name.replace('.so', '_symlink_check'), |
10 | | - os.path.dirname(__file__), **kwargs) |
11 | | - |
| 7 | +@rfm.parameterized_test(['libsci_acc_gnu_49_nv20'], |
| 8 | + ['libsci_acc_gnu_49_nv35'], |
| 9 | + ['libsci_acc_gnu_49_nv60'], |
| 10 | + ['libsci_acc_cray_nv20_openacc'], |
| 11 | + ['libsci_acc_cray_nv35_openacc'], |
| 12 | + ['libsci_acc_cray_nv60_openacc']) |
| 13 | +class LibSciAccSymLinkTest(rfm.RunOnlyRegressionTest): |
| 14 | + def __init__(self, lib_name): |
| 15 | + super().__init__() |
12 | 16 | self.descr = 'LibSciAcc symlink check of %s' % lib_name |
13 | | - self.valid_systems = ['daint:login', 'dom:login'] |
| 17 | + self.valid_systems = ['daint:login', 'daint:gpu', |
| 18 | + 'dom:login', 'dom:gpu'] |
14 | 19 |
|
15 | 20 | # The prgenv is irrelevant for this case, so just chose one |
16 | 21 | self.valid_prog_environs = ['PrgEnv-cray'] |
17 | | - |
18 | 22 | self.executable = 'ls' |
19 | | - self.executable_opts = '-al /opt/cray/pe/lib64/libsci_a*'.split() |
20 | | - self.sanity_patterns = sn.assert_found(lib_name, self.stdout) |
| 23 | + self.executable_opts = ['-al', '/opt/cray/pe/lib64/libsci_a*'] |
| 24 | + self.sanity_patterns = sn.assert_found(lib_name + '.so', self.stdout) |
| 25 | + |
21 | 26 | self.maintainers = ['AJ'] |
22 | 27 | self.tags = {'production'} |
23 | | - |
24 | | - |
25 | | -def _get_checks(**kwargs): |
26 | | - |
27 | | - ret = [] |
28 | | - for lib_name in [r'libsci_acc_gnu_49_nv20.so', |
29 | | - r'libsci_acc_gnu_49_nv35.so', |
30 | | - r'libsci_acc_gnu_49_nv60.so', |
31 | | - r'libsci_acc_cray_nv20_openacc.so', |
32 | | - r'libsci_acc_cray_nv35_openacc.so', |
33 | | - r'libsci_acc_cray_nv60_openacc.so']: |
34 | | - ret.append(LibSciAccSymLinkTest(lib_name, **kwargs)) |
35 | | - |
36 | | - return ret |
0 commit comments