Commit 32f4fa3
committed
Random / parallel testing
This patch updates VM Op to run its unit/integration tests in a
random order, in parallel (using as many processes as there are
CPUs).
This change reduces the time to test one of the larger packages,
./pkg/providers/vsphere, from 502s to only 88s.
The randomization also ensures both the production code and test
code is reslient and more decomposed.
Finally, if there is a need to maintain ordering, because VM Op
uses Ginkgo v2, the Ordered decorator may be utilized. There are
examples of this in the code-base already, such as in
./pkg/exit/exit_test.go. Just search the project for `Ordered,` to
find such examples, ex.: `grep -r 'Ordered,' * `.1 parent cd82190 commit 32f4fa3
File tree
3 files changed
+21
-6
lines changed- hack
- pkg/util
- cloudinit
- vsphere/vm
3 files changed
+21
-6
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
13 | 13 | | |
14 | 14 | | |
15 | 15 | | |
16 | | - | |
17 | | - | |
18 | | - | |
19 | | - | |
| 16 | + | |
| 17 | + | |
| 18 | + | |
| 19 | + | |
| 20 | + | |
| 21 | + | |
| 22 | + | |
| 23 | + | |
| 24 | + | |
| 25 | + | |
| 26 | + | |
| 27 | + | |
20 | 28 | | |
21 | 29 | | |
22 | 30 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
184 | 184 | | |
185 | 185 | | |
186 | 186 | | |
187 | | - | |
| 187 | + | |
| 188 | + | |
| 189 | + | |
| 190 | + | |
| 191 | + | |
| 192 | + | |
| 193 | + | |
| 194 | + | |
188 | 195 | | |
189 | 196 | | |
190 | 197 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
484 | 484 | | |
485 | 485 | | |
486 | 486 | | |
487 | | - | |
| 487 | + | |
488 | 488 | | |
489 | 489 | | |
490 | 490 | | |
| |||
0 commit comments