File tree Expand file tree Collapse file tree 3 files changed +10
-32
lines changed Expand file tree Collapse file tree 3 files changed +10
-32
lines changed Original file line number Diff line number Diff line change @@ -178,10 +178,10 @@ def load_from_module(self, module):
178178 continue
179179
180180 # Get the original filename in case of a different module name
181- testfile = (
182- module . __file__ if module .__name__ == c . __module__ else
183- inspect . getfile ( c . __class__ )
184- )
181+ if module . __name__ == c . __module__ :
182+ testfile = module .__file__
183+ else :
184+ testfile = inspect . getfile ( c . __class__ )
185185
186186 try :
187187 conflicted = self ._loaded [c .unique_name ]
Load Diff This file was deleted.
Original file line number Diff line number Diff line change 99import reframe .utility .sanity as sn
1010
1111
12- class simple_echo (rfm .RunOnlyRegressionTest , pin_prefix = True ):
13- descr = 'Simple Echo build fixture'
12+ class dummy_fixture (rfm .RunOnlyRegressionTest , pin_prefix = True ):
1413 executable = 'echo'
15- executable_opts = ['Hello' ]
16-
17- @sanity_function
18- def assert_success (self ):
19- return sn .assert_found (r'Hello' , self .stdout )
14+ sanity_patterns = sn .assert_true (1 )
2015
2116
2217@rfm .simple_test
@@ -25,14 +20,13 @@ class simple_echo_check(rfm.RunOnlyRegressionTest):
2520 valid_systems = ['*' ]
2621 valid_prog_environs = ['builtin' ]
2722 executable = 'echo'
23+ executable_opts = ['Hello' ]
2824 message = variable (str , value = 'World' )
29- hello_output = fixture (simple_echo , scope = 'environment' )
25+ dummy = fixture (dummy_fixture , scope = 'environment' )
3026
3127 @run_before ('run' )
32- def add_exec_prefix (self ):
33- fixture_output = os .path .join (self .hello_output .stagedir ,
34- str (self .hello_output .stdout ))
35- self .executable_opts = [f'$(cat { fixture_output } )' , self .message ]
28+ def set_executable_opts (self ):
29+ self .executable_opts += [self .message ]
3630
3731 @sanity_function
3832 def assert_sanity (self ):
You can’t perform that action at this time.
0 commit comments