@@ -20,6 +20,7 @@ def setUp(self):
2020
2121 # 0.001 hour translates to 3.6 seconds, which will definitely cause failure.
2222 timeout_flags = ["--timeout 0.001" , "--timeout_per_trial 0.001" ]
23+ self .timeout_limit = 15 # 15 second upper limit
2324 self .commands = [
2425 "python3 distributed.py"
2526 f" --design { self .design } "
@@ -45,9 +46,11 @@ class ASAP7TimeoutSmokeTest(BaseTimeoutSmokeTest):
4546
4647 def test_timeout (self ):
4748 for command in self .commands :
48- out = subprocess .run (command , shell = True , check = True )
49+ out = subprocess .run (
50+ command , shell = True , check = True , timeout = self .timeout_limit
51+ )
4952 successful = out .returncode == 0
50- self .assertFalse (successful )
53+ self .assertTrue (successful )
5154
5255
5356class SKY130HDTimeoutSmokeTest (BaseTimeoutSmokeTest ):
@@ -56,9 +59,11 @@ class SKY130HDTimeoutSmokeTest(BaseTimeoutSmokeTest):
5659
5760 def test_timeout (self ):
5861 for command in self .commands :
59- out = subprocess .run (command , shell = True , check = True )
62+ out = subprocess .run (
63+ command , shell = True , check = True , timeout = self .timeout_limit
64+ )
6065 successful = out .returncode == 0
61- self .assertFalse (successful )
66+ self .assertTrue (successful )
6267
6368
6469class IHPSG13G2TimeoutSmokeTest (BaseTimeoutSmokeTest ):
@@ -67,9 +72,11 @@ class IHPSG13G2TimeoutSmokeTest(BaseTimeoutSmokeTest):
6772
6873 def test_timeout (self ):
6974 for command in self .commands :
70- out = subprocess .run (command , shell = True , check = True )
75+ out = subprocess .run (
76+ command , shell = True , check = True , timeout = self .timeout_limit
77+ )
7178 successful = out .returncode == 0
72- self .assertFalse (successful )
79+ self .assertTrue (successful )
7380
7481
7582if __name__ == "__main__" :
0 commit comments