@@ -173,36 +173,44 @@ test("Stopping Worker after creating another runtime doesn't fail", async (t) =>
173173 const runtime1 = native . newRuntime ( GenericConfigs . runtime . basic ) ;
174174
175175 // Starts Worker 0
176+ console . log ( 'Starting Worker 0' ) ;
176177 const client0 = await native . newClient ( runtime0 , GenericConfigs . client . basic ) ;
177178 const worker0 = native . newWorker ( client0 , GenericConfigs . worker . basic ) ;
178179 await native . workerValidate ( worker0 ) ;
179180
180181 // Start Worker 1
182+ console . log ( 'Starting Worker 1' ) ;
181183 const client1 = await native . newClient ( runtime1 , GenericConfigs . client . basic ) ;
182184 const worker1 = native . newWorker ( client1 , GenericConfigs . worker . basic ) ;
183185 await native . workerValidate ( worker1 ) ;
184186
185187 // Start polling on Worker 1 (note reverse order of Worker 0)
188+ console . log ( 'Starting polling on Worker 1' ) ;
186189 const wftPromise1 = native . workerPollWorkflowActivation ( worker1 ) ;
187190 const atPromise1 = native . workerPollActivityTask ( worker1 ) ;
188191
189192 // Start polling on Worker 0
193+ console . log ( 'Starting polling on Worker 0' ) ;
190194 const wftPromise0 = native . workerPollWorkflowActivation ( worker0 ) ;
191195 const atPromise0 = native . workerPollActivityTask ( worker0 ) ;
192196
193197 // Cleanly shutdown Worker 1
198+ console . log ( 'Shutting down Worker 1' ) ;
194199 native . workerInitiateShutdown ( worker1 ) ;
195200 await expectShutdownError ( wftPromise1 ) ;
196201 await expectShutdownError ( atPromise1 ) ;
197202 await native . workerFinalizeShutdown ( worker1 ) ;
198203 // Leave Client 1 and Runtime 1 alive
204+ console . log ( 'Leave Client 1 and Runtime 1 alive' ) ;
199205
200206 // Create Runtime 2 and Worker 2, but don't immediately use them
207+ console . log ( 'Creating Worker 2' ) ;
201208 const runtime2 = native . newRuntime ( GenericConfigs . runtime . basic ) ;
202209 const client2 = await native . newClient ( runtime2 , GenericConfigs . client . basic ) ;
203210 const worker2 = native . newWorker ( client2 , GenericConfigs . worker . basic ) ;
204211
205212 // Cleanly shutdown Worker 0
213+ console . log ( 'Shutting down Worker 0' ) ;
206214 native . workerInitiateShutdown ( worker0 ) ;
207215 await expectShutdownError ( wftPromise0 ) ;
208216 await expectShutdownError ( atPromise0 ) ;
@@ -211,9 +219,11 @@ test("Stopping Worker after creating another runtime doesn't fail", async (t) =>
211219 native . runtimeShutdown ( runtime0 ) ;
212220
213221 // Start yet another runtime, we really won't use it
222+ console . log ( "Start yet another runtime, we really won't use it" ) ;
214223 const _runtime3 = native . newRuntime ( GenericConfigs . runtime . basic ) ;
215224
216225 // Start polling on Worker 2, then shut it down cleanly
226+ console . log ( 'Starting polling on Worker 2' ) ;
217227 await native . workerValidate ( worker2 ) ;
218228 const wftPromise2 = native . workerPollWorkflowActivation ( worker2 ) ; // TODO: failing here
219229 const atPromise2 = native . workerPollActivityTask ( worker2 ) ;
@@ -223,6 +233,7 @@ test("Stopping Worker after creating another runtime doesn't fail", async (t) =>
223233 await native . workerFinalizeShutdown ( worker2 ) ;
224234 native . clientClose ( client2 ) ;
225235 native . runtimeShutdown ( runtime2 ) ;
236+ console . log ( 't.pass()' ) ;
226237
227238 t . pass ( ) ;
228239} ) ;
0 commit comments