Commit e4f7ca0
authored
Clean up a variety of tests that create blueprints (#9393)
I'd like to add a couple new fields to `BlueprintSledConfig`, and doing
so broke a variety of tests in annoying ways. Many of those tests have
required annoying changes in the past, too. This PR doesn't add any new
fields, but instead attempts to clean up those tests so changes to
Reconfigurator structures are less likely to cause problems (and
hopefully any problems will be easier to fix). A couple techniques:
* Some tests that were creating raw blueprints by hand now use either
`BlueprintBuilder` or `ExampleSystemBuilder`
* Replaces `BlueprintBuilder::build_empty_with_sleds{,_seeded}` with
`BlueprintBuilder::build_empty{,_seeded}`. The former added some sleds
with nothing on them; the latter adds no sleds at all. I updated all the
callers of `build_empty_with_sleds` to either use `build_empty`
(actually fine for most of them) or the example system infrastructure.
This does add a few new helper methods on real types; e.g.,
`BlueprintBuilder::sled_add_zone_boundary_ntp()` (for directly adding a
boundary NTP instead of promoting an existing internal NTP zone). But
currently only tests call these new methods, and I don't think they're
prone to misuse; e.g., `sled_add_zone_boundary_ntp()` checks and fails
if called on a sled that already has an in-service NTP zone of either
flavor.1 parent 2f86dda commit e4f7ca0
File tree
12 files changed
+708
-1104
lines changed- dev-tools/reconfigurator-cli/tests/output
- nexus
- db-queries/src/db/datastore
- deployment
- reconfigurator
- execution/src
- planning/src
- blueprint_builder
- src/app/background/tasks
- types/src/deployment
12 files changed
+708
-1104
lines changedLines changed: 14 additions & 14 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
26 | 26 | | |
27 | 27 | | |
28 | 28 | | |
29 | | - | |
| 29 | + | |
30 | 30 | | |
31 | 31 | | |
32 | 32 | | |
33 | 33 | | |
34 | 34 | | |
35 | 35 | | |
36 | 36 | | |
37 | | - | |
| 37 | + | |
38 | 38 | | |
39 | 39 | | |
40 | 40 | | |
| |||
43 | 43 | | |
44 | 44 | | |
45 | 45 | | |
46 | | - | |
| 46 | + | |
47 | 47 | | |
48 | 48 | | |
49 | 49 | | |
| |||
64 | 64 | | |
65 | 65 | | |
66 | 66 | | |
67 | | - | |
| 67 | + | |
68 | 68 | | |
69 | 69 | | |
70 | 70 | | |
71 | 71 | | |
72 | | - | |
| 72 | + | |
73 | 73 | | |
74 | | - | |
| 74 | + | |
75 | 75 | | |
76 | 76 | | |
77 | 77 | | |
78 | 78 | | |
79 | 79 | | |
80 | | - | |
81 | | - | |
| 80 | + | |
| 81 | + | |
82 | 82 | | |
83 | 83 | | |
84 | 84 | | |
| |||
184 | 184 | | |
185 | 185 | | |
186 | 186 | | |
187 | | - | |
| 187 | + | |
188 | 188 | | |
189 | 189 | | |
190 | 190 | | |
191 | 191 | | |
192 | 192 | | |
193 | | - | |
194 | | - | |
| 193 | + | |
| 194 | + | |
195 | 195 | | |
196 | 196 | | |
197 | 197 | | |
| |||
294 | 294 | | |
295 | 295 | | |
296 | 296 | | |
297 | | - | |
| 297 | + | |
298 | 298 | | |
299 | 299 | | |
300 | 300 | | |
301 | 301 | | |
302 | 302 | | |
303 | | - | |
304 | | - | |
| 303 | + | |
| 304 | + | |
305 | 305 | | |
306 | 306 | | |
307 | 307 | | |
| |||
Lines changed: 8 additions & 8 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
694 | 694 | | |
695 | 695 | | |
696 | 696 | | |
697 | | - | |
| 697 | + | |
698 | 698 | | |
699 | | - | |
| 699 | + | |
700 | 700 | | |
701 | 701 | | |
702 | 702 | | |
703 | 703 | | |
704 | 704 | | |
705 | | - | |
706 | | - | |
| 705 | + | |
| 706 | + | |
707 | 707 | | |
708 | 708 | | |
709 | 709 | | |
| |||
914 | 914 | | |
915 | 915 | | |
916 | 916 | | |
917 | | - | |
| 917 | + | |
918 | 918 | | |
919 | | - | |
| 919 | + | |
920 | 920 | | |
921 | 921 | | |
922 | 922 | | |
923 | 923 | | |
924 | 924 | | |
925 | | - | |
926 | | - | |
| 925 | + | |
| 926 | + | |
927 | 927 | | |
928 | 928 | | |
929 | 929 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
3146 | 3146 | | |
3147 | 3147 | | |
3148 | 3148 | | |
3149 | | - | |
3150 | 3149 | | |
3151 | 3150 | | |
3152 | | - | |
3153 | 3151 | | |
3154 | | - | |
3155 | 3152 | | |
3156 | 3153 | | |
3157 | 3154 | | |
3158 | 3155 | | |
3159 | 3156 | | |
3160 | 3157 | | |
3161 | 3158 | | |
3162 | | - | |
3163 | 3159 | | |
3164 | 3160 | | |
3165 | 3161 | | |
| |||
3168 | 3164 | | |
3169 | 3165 | | |
3170 | 3166 | | |
3171 | | - | |
3172 | | - | |
3173 | 3167 | | |
3174 | 3168 | | |
3175 | 3169 | | |
3176 | | - | |
3177 | | - | |
3178 | | - | |
3179 | 3170 | | |
3180 | 3171 | | |
3181 | 3172 | | |
3182 | | - | |
3183 | 3173 | | |
3184 | 3174 | | |
3185 | 3175 | | |
3186 | | - | |
3187 | 3176 | | |
3188 | 3177 | | |
3189 | 3178 | | |
3190 | 3179 | | |
3191 | | - | |
3192 | 3180 | | |
3193 | 3181 | | |
3194 | 3182 | | |
3195 | 3183 | | |
3196 | | - | |
3197 | | - | |
3198 | 3184 | | |
3199 | | - | |
3200 | | - | |
3201 | 3185 | | |
3202 | 3186 | | |
3203 | 3187 | | |
| |||
3311 | 3295 | | |
3312 | 3296 | | |
3313 | 3297 | | |
3314 | | - | |
3315 | | - | |
3316 | | - | |
3317 | | - | |
| 3298 | + | |
3318 | 3299 | | |
3319 | 3300 | | |
3320 | 3301 | | |
| |||
4039 | 4020 | | |
4040 | 4021 | | |
4041 | 4022 | | |
4042 | | - | |
4043 | | - | |
4044 | | - | |
4045 | | - | |
| 4023 | + | |
4046 | 4024 | | |
4047 | 4025 | | |
4048 | 4026 | | |
| |||
4190 | 4168 | | |
4191 | 4169 | | |
4192 | 4170 | | |
4193 | | - | |
4194 | | - | |
4195 | | - | |
4196 | | - | |
| 4171 | + | |
4197 | 4172 | | |
4198 | 4173 | | |
4199 | 4174 | | |
| |||
4292 | 4267 | | |
4293 | 4268 | | |
4294 | 4269 | | |
4295 | | - | |
4296 | | - | |
4297 | | - | |
4298 | | - | |
4299 | | - | |
4300 | | - | |
4301 | | - | |
4302 | | - | |
4303 | | - | |
4304 | | - | |
4305 | | - | |
4306 | | - | |
4307 | | - | |
4308 | | - | |
4309 | | - | |
4310 | | - | |
4311 | | - | |
4312 | | - | |
4313 | | - | |
4314 | | - | |
4315 | | - | |
4316 | | - | |
4317 | | - | |
4318 | | - | |
4319 | | - | |
4320 | | - | |
4321 | | - | |
4322 | | - | |
4323 | | - | |
4324 | | - | |
4325 | | - | |
4326 | | - | |
4327 | | - | |
4328 | | - | |
4329 | | - | |
4330 | | - | |
4331 | | - | |
4332 | | - | |
4333 | | - | |
4334 | | - | |
4335 | | - | |
4336 | | - | |
4337 | | - | |
4338 | | - | |
4339 | | - | |
4340 | | - | |
4341 | | - | |
4342 | | - | |
4343 | | - | |
4344 | | - | |
4345 | | - | |
4346 | | - | |
4347 | | - | |
4348 | | - | |
4349 | | - | |
4350 | | - | |
4351 | | - | |
4352 | | - | |
4353 | | - | |
4354 | | - | |
4355 | | - | |
4356 | | - | |
4357 | | - | |
4358 | | - | |
4359 | | - | |
4360 | | - | |
4361 | | - | |
4362 | | - | |
4363 | | - | |
4364 | | - | |
4365 | | - | |
4366 | | - | |
4367 | | - | |
4368 | | - | |
4369 | | - | |
4370 | | - | |
4371 | | - | |
4372 | | - | |
4373 | | - | |
4374 | | - | |
4375 | | - | |
4376 | | - | |
4377 | | - | |
4378 | | - | |
4379 | | - | |
4380 | | - | |
4381 | | - | |
4382 | 4270 | | |
4383 | 4271 | | |
| 4272 | + | |
| 4273 | + | |
4384 | 4274 | | |
4385 | | - | |
4386 | | - | |
4387 | | - | |
| 4275 | + | |
4388 | 4276 | | |
4389 | 4277 | | |
4390 | 4278 | | |
4391 | | - | |
4392 | | - | |
| 4279 | + | |
| 4280 | + | |
| 4281 | + | |
| 4282 | + | |
| 4283 | + | |
| 4284 | + | |
| 4285 | + | |
| 4286 | + | |
| 4287 | + | |
| 4288 | + | |
| 4289 | + | |
| 4290 | + | |
| 4291 | + | |
| 4292 | + | |
| 4293 | + | |
| 4294 | + | |
| 4295 | + | |
| 4296 | + | |
| 4297 | + | |
| 4298 | + | |
| 4299 | + | |
| 4300 | + | |
| 4301 | + | |
| 4302 | + | |
| 4303 | + | |
| 4304 | + | |
| 4305 | + | |
| 4306 | + | |
| 4307 | + | |
| 4308 | + | |
| 4309 | + | |
4393 | 4310 | | |
4394 | 4311 | | |
4395 | 4312 | | |
| |||
0 commit comments