Commit 13a3aac
authored
More tests (#51)
This PR adds
* many tests (listed below)
* ability to register a workflow with a custom name.
* returns an error (instead of a emitting a warning) when a workflow is
enqueued in a different queue.
Custom name registration: we don't have custom interfaces / struct for
workflows and at runtime have only access to the reflection-found
workflow full qualified name. So we leverage the existing mechanism to
retrieve registration-time workflow parameters (the registry is indexed
by reflection names). This should be consistent within application
versions, but remember that reflection names can change if the code
changes.
Added Tests:
1. Queue Conflicting Workflows: Tests that workflows with the same ID on
different queues trigger ConflictingWorkflowError
2. Workflow Registration: Tests for double registration scenarios
(with/without custom names)
3. Dynamic Registration: Tests that registering queues/workflows after
launch panics
4. Child Workflow Recovery: Tests polling handles for recovered child
workflows
5. concurrency tests: 3 new tests with 500 concurrent simple workflow,
sender/receiver, setter/getter
6. Verify step IDs and names for `Send`, `Receive`, `SetEvent`,
`GetEvent`1 parent c965f36 commit 13a3aac
File tree
4 files changed
+906
-30
lines changed- dbos
4 files changed
+906
-30
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
5 | 5 | | |
6 | 6 | | |
7 | 7 | | |
| 8 | + | |
8 | 9 | | |
9 | 10 | | |
10 | 11 | | |
| |||
23 | 24 | | |
24 | 25 | | |
25 | 26 | | |
| 27 | + | |
26 | 28 | | |
27 | 29 | | |
28 | 30 | | |
| |||
48 | 50 | | |
49 | 51 | | |
50 | 52 | | |
| 53 | + | |
| 54 | + | |
51 | 55 | | |
52 | 56 | | |
53 | 57 | | |
| |||
172 | 176 | | |
173 | 177 | | |
174 | 178 | | |
175 | | - | |
176 | 179 | | |
177 | | - | |
178 | | - | |
179 | | - | |
180 | | - | |
| 180 | + | |
| 181 | + | |
| 182 | + | |
| 183 | + | |
| 184 | + | |
| 185 | + | |
| 186 | + | |
181 | 187 | | |
182 | | - | |
183 | 188 | | |
184 | 189 | | |
185 | 190 | | |
| |||
255 | 260 | | |
256 | 261 | | |
257 | 262 | | |
| 263 | + | |
| 264 | + | |
| 265 | + | |
| 266 | + | |
| 267 | + | |
| 268 | + | |
| 269 | + | |
| 270 | + | |
| 271 | + | |
| 272 | + | |
| 273 | + | |
| 274 | + | |
| 275 | + | |
| 276 | + | |
| 277 | + | |
| 278 | + | |
| 279 | + | |
| 280 | + | |
| 281 | + | |
| 282 | + | |
| 283 | + | |
| 284 | + | |
| 285 | + | |
| 286 | + | |
| 287 | + | |
| 288 | + | |
| 289 | + | |
| 290 | + | |
| 291 | + | |
| 292 | + | |
| 293 | + | |
| 294 | + | |
| 295 | + | |
| 296 | + | |
| 297 | + | |
| 298 | + | |
| 299 | + | |
| 300 | + | |
| 301 | + | |
| 302 | + | |
| 303 | + | |
| 304 | + | |
| 305 | + | |
| 306 | + | |
| 307 | + | |
| 308 | + | |
258 | 309 | | |
259 | 310 | | |
260 | 311 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
380 | 380 | | |
381 | 381 | | |
382 | 382 | | |
383 | | - | |
| 383 | + | |
384 | 384 | | |
385 | 385 | | |
386 | 386 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
8 | 8 | | |
9 | 9 | | |
10 | 10 | | |
| 11 | + | |
11 | 12 | | |
12 | 13 | | |
13 | 14 | | |
| |||
204 | 205 | | |
205 | 206 | | |
206 | 207 | | |
| 208 | + | |
207 | 209 | | |
208 | 210 | | |
209 | 211 | | |
210 | | - | |
| 212 | + | |
211 | 213 | | |
212 | 214 | | |
213 | 215 | | |
| |||
221 | 223 | | |
222 | 224 | | |
223 | 225 | | |
224 | | - | |
225 | | - | |
226 | | - | |
| 226 | + | |
| 227 | + | |
| 228 | + | |
227 | 229 | | |
228 | 230 | | |
229 | | - | |
| 231 | + | |
230 | 232 | | |
231 | 233 | | |
| 234 | + | |
232 | 235 | | |
233 | 236 | | |
234 | 237 | | |
| |||
274 | 277 | | |
275 | 278 | | |
276 | 279 | | |
| 280 | + | |
277 | 281 | | |
278 | 282 | | |
279 | 283 | | |
| |||
294 | 298 | | |
295 | 299 | | |
296 | 300 | | |
| 301 | + | |
| 302 | + | |
| 303 | + | |
| 304 | + | |
| 305 | + | |
| 306 | + | |
297 | 307 | | |
298 | 308 | | |
299 | 309 | | |
| |||
347 | 357 | | |
348 | 358 | | |
349 | 359 | | |
350 | | - | |
| 360 | + | |
351 | 361 | | |
352 | 362 | | |
353 | 363 | | |
| |||
397 | 407 | | |
398 | 408 | | |
399 | 409 | | |
| 410 | + | |
400 | 411 | | |
401 | 412 | | |
402 | 413 | | |
| |||
484 | 495 | | |
485 | 496 | | |
486 | 497 | | |
| 498 | + | |
| 499 | + | |
| 500 | + | |
487 | 501 | | |
488 | 502 | | |
489 | 503 | | |
| |||
705 | 719 | | |
706 | 720 | | |
707 | 721 | | |
708 | | - | |
| 722 | + | |
| 723 | + | |
| 724 | + | |
| 725 | + | |
| 726 | + | |
| 727 | + | |
709 | 728 | | |
710 | 729 | | |
711 | 730 | | |
| |||
719 | 738 | | |
720 | 739 | | |
721 | 740 | | |
722 | | - | |
| 741 | + | |
723 | 742 | | |
724 | | - | |
| 743 | + | |
| 744 | + | |
| 745 | + | |
725 | 746 | | |
726 | 747 | | |
727 | 748 | | |
728 | 749 | | |
729 | 750 | | |
730 | | - | |
| 751 | + | |
731 | 752 | | |
732 | 753 | | |
733 | 754 | | |
| |||
742 | 763 | | |
743 | 764 | | |
744 | 765 | | |
745 | | - | |
| 766 | + | |
| 767 | + | |
746 | 768 | | |
747 | 769 | | |
748 | 770 | | |
| |||
0 commit comments