File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -89,21 +89,21 @@ def test_timeout(self) -> None:
8989 import time
9090
9191 def slow (x : int ) -> int :
92- time .sleep (5 .0 )
92+ time .sleep (30 .0 )
9393 return x
9494
95- wf = Workflow ("timeout-wf" ).step ("slow" , slow , timeout = 0.1 ).build ()
95+ wf = Workflow ("timeout-wf" ).step ("slow" , slow , timeout = 0.5 ).build ()
9696 with pytest .raises (TimeoutError , match = "timed out" ):
9797 wf .run (1 )
9898
9999 def test_timeout_includes_step_name (self ) -> None :
100100 import time
101101
102102 def slow (x : int ) -> int :
103- time .sleep (5 .0 )
103+ time .sleep (30 .0 )
104104 return x
105105
106- wf = Workflow ("named-timeout" ).step ("my_step" , slow , timeout = 0.1 ).build ()
106+ wf = Workflow ("named-timeout" ).step ("my_step" , slow , timeout = 0.5 ).build ()
107107 with pytest .raises (TimeoutError , match = "my_step" ):
108108 wf .run (1 )
109109
@@ -143,10 +143,10 @@ async def async_double(x: int) -> int:
143143
144144 async def test_timeout (self ) -> None :
145145 async def slow (x : int ) -> int :
146- await asyncio .sleep (5 .0 )
146+ await asyncio .sleep (30 .0 )
147147 return x
148148
149- wf = AsyncWorkflow ("timeout-wf" ).step ("slow" , slow , timeout = 0.01 ).build ()
149+ wf = AsyncWorkflow ("timeout-wf" ).step ("slow" , slow , timeout = 0.5 ).build ()
150150 with pytest .raises (asyncio .TimeoutError ):
151151 await wf .run (1 )
152152
You can’t perform that action at this time.
0 commit comments