Update Testcontainers to v4 and migrate to ICollectionFixture - #8350
Update Testcontainers to v4 and migrate to ICollectionFixture#8350bouwkast wants to merge 2 commits into
Conversation
BenchmarksBenchmark execution time: 2026-07-29 15:08:54 Comparing candidate commit 36b956d in PR branch Found 0 performance improvements and 1 performance regressions! Performance is the same for 71 metrics, 0 unstable metrics, 61 known flaky benchmarks, 65 flaky benchmarks without significant changes.
|
Execution-Time Benchmarks Report ⏱️Execution-time results for samples comparing This PR (8350) and master.
|
|||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| Metric | Master (Mean ± 95% CI) | Current (Mean ± 95% CI) | Change | Status |
|---|---|---|---|---|
| .NET Framework 4.8 - Baseline | ||||
| duration | 204.99 ± (204.93 - 205.88) ms | 216.85 ± (216.40 - 217.39) ms | +5.8% | ❌⬆️ |
Full Metrics Comparison
FakeDbCommand
| Metric | Master (Mean ± 95% CI) | Current (Mean ± 95% CI) | Change | Status |
|---|---|---|---|---|
| .NET Framework 4.8 - Baseline | ||||
| duration | 71.68 ± (71.73 - 72.16) ms | 73.44 ± (73.09 - 73.64) ms | +2.5% | ✅⬆️ |
| .NET Framework 4.8 - Bailout | ||||
| duration | 78.42 ± (78.10 - 78.59) ms | 78.57 ± (78.14 - 78.69) ms | +0.2% | ✅⬆️ |
| .NET Framework 4.8 - CallTarget+Inlining+NGEN | ||||
| duration | 1087.49 ± (1086.77 - 1093.07) ms | 1084.51 ± (1083.14 - 1088.75) ms | -0.3% | ✅ |
| .NET Core 3.1 - Baseline | ||||
| process.internal_duration_ms | 22.38 ± (22.34 - 22.42) ms | 22.34 ± (22.29 - 22.38) ms | -0.2% | ✅ |
| process.time_to_main_ms | 84.10 ± (83.85 - 84.36) ms | 84.56 ± (84.28 - 84.83) ms | +0.5% | ✅⬆️ |
| runtime.dotnet.exceptions.count | 0 ± (0 - 0) | 0 ± (0 - 0) | +0.0% | ✅ |
| runtime.dotnet.mem.committed | 10.98 ± (10.98 - 10.99) MB | 11.00 ± (11.00 - 11.01) MB | +0.2% | ✅⬆️ |
| runtime.dotnet.threads.count | 12 ± (12 - 12) | 12 ± (12 - 12) | +0.0% | ✅ |
| .NET Core 3.1 - Bailout | ||||
| process.internal_duration_ms | 22.04 ± (22.02 - 22.07) ms | 21.95 ± (21.93 - 21.98) ms | -0.4% | ✅ |
| process.time_to_main_ms | 83.68 ± (83.47 - 83.88) ms | 83.11 ± (82.91 - 83.30) ms | -0.7% | ✅ |
| runtime.dotnet.exceptions.count | 0 ± (0 - 0) | 0 ± (0 - 0) | +0.0% | ✅ |
| runtime.dotnet.mem.committed | 11.03 ± (11.03 - 11.03) MB | 11.04 ± (11.04 - 11.05) MB | +0.1% | ✅⬆️ |
| runtime.dotnet.threads.count | 13 ± (13 - 13) | 13 ± (13 - 13) | +0.0% | ✅ |
| .NET Core 3.1 - CallTarget+Inlining+NGEN | ||||
| process.internal_duration_ms | 209.92 ± (209.02 - 210.82) ms | 209.84 ± (209.08 - 210.60) ms | -0.0% | ✅ |
| process.time_to_main_ms | 538.02 ± (536.78 - 539.25) ms | 537.79 ± (536.71 - 538.86) ms | -0.0% | ✅ |
| runtime.dotnet.exceptions.count | 0 ± (0 - 0) | 0 ± (0 - 0) | +0.0% | ✅ |
| runtime.dotnet.mem.committed | 49.53 ± (49.50 - 49.56) MB | 49.55 ± (49.52 - 49.58) MB | +0.0% | ✅⬆️ |
| runtime.dotnet.threads.count | 28 ± (28 - 28) | 28 ± (28 - 28) | +0.3% | ✅⬆️ |
| .NET 6 - Baseline | ||||
| process.internal_duration_ms | 20.81 ± (20.78 - 20.84) ms | 20.98 ± (20.93 - 21.02) ms | +0.8% | ✅⬆️ |
| process.time_to_main_ms | 71.63 ± (71.46 - 71.80) ms | 71.96 ± (71.71 - 72.21) ms | +0.5% | ✅⬆️ |
| runtime.dotnet.exceptions.count | 0 ± (0 - 0) | 0 ± (0 - 0) | +0.0% | ✅ |
| runtime.dotnet.mem.committed | 10.71 ± (10.71 - 10.71) MB | 10.72 ± (10.71 - 10.72) MB | +0.1% | ✅⬆️ |
| runtime.dotnet.threads.count | 10 ± (10 - 10) | 10 ± (10 - 10) | +0.0% | ✅ |
| .NET 6 - Bailout | ||||
| process.internal_duration_ms | 20.77 ± (20.74 - 20.80) ms | 21.06 ± (21.02 - 21.10) ms | +1.4% | ✅⬆️ |
| process.time_to_main_ms | 72.61 ± (72.48 - 72.74) ms | 74.62 ± (74.41 - 74.84) ms | +2.8% | ✅⬆️ |
| runtime.dotnet.exceptions.count | 0 ± (0 - 0) | 0 ± (0 - 0) | +0.0% | ✅ |
| runtime.dotnet.mem.committed | 10.83 ± (10.83 - 10.84) MB | 10.84 ± (10.84 - 10.85) MB | +0.1% | ✅⬆️ |
| runtime.dotnet.threads.count | 11 ± (11 - 11) | 11 ± (11 - 11) | +0.0% | ✅ |
| .NET 6 - CallTarget+Inlining+NGEN | ||||
| process.internal_duration_ms | 372.11 ± (369.95 - 374.27) ms | 372.79 ± (370.58 - 375.00) ms | +0.2% | ✅⬆️ |
| process.time_to_main_ms | 547.53 ± (546.34 - 548.72) ms | 543.58 ± (542.38 - 544.78) ms | -0.7% | ✅ |
| runtime.dotnet.exceptions.count | 0 ± (0 - 0) | 0 ± (0 - 0) | +0.0% | ✅ |
| runtime.dotnet.mem.committed | 50.64 ± (50.62 - 50.66) MB | 50.62 ± (50.60 - 50.65) MB | -0.0% | ✅ |
| runtime.dotnet.threads.count | 28 ± (28 - 28) | 28 ± (28 - 28) | -0.2% | ✅ |
| .NET 8 - Baseline | ||||
| process.internal_duration_ms | 19.47 ± (19.42 - 19.52) ms | 19.25 ± (19.22 - 19.27) ms | -1.2% | ✅ |
| process.time_to_main_ms | 73.39 ± (73.14 - 73.63) ms | 69.95 ± (69.83 - 70.08) ms | -4.7% | ✅ |
| runtime.dotnet.exceptions.count | 0 ± (0 - 0) | 0 ± (0 - 0) | +0.0% | ✅ |
| runtime.dotnet.mem.committed | 7.75 ± (7.74 - 7.75) MB | 7.78 ± (7.77 - 7.78) MB | +0.3% | ✅⬆️ |
| runtime.dotnet.threads.count | 10 ± (10 - 10) | 10 ± (10 - 10) | +0.0% | ✅ |
| .NET 8 - Bailout | ||||
| process.internal_duration_ms | 19.18 ± (19.14 - 19.21) ms | 19.16 ± (19.12 - 19.19) ms | -0.1% | ✅ |
| process.time_to_main_ms | 72.38 ± (72.19 - 72.57) ms | 71.22 ± (71.11 - 71.34) ms | -1.6% | ✅ |
| runtime.dotnet.exceptions.count | 0 ± (0 - 0) | 0 ± (0 - 0) | +0.0% | ✅ |
| runtime.dotnet.mem.committed | 7.80 ± (7.80 - 7.80) MB | 7.81 ± (7.81 - 7.82) MB | +0.2% | ✅⬆️ |
| runtime.dotnet.threads.count | 11 ± (11 - 11) | 11 ± (11 - 11) | +0.0% | ✅ |
| .NET 8 - CallTarget+Inlining+NGEN | ||||
| process.internal_duration_ms | 294.06 ± (292.12 - 296.01) ms | 297.42 ± (295.16 - 299.68) ms | +1.1% | ✅⬆️ |
| process.time_to_main_ms | 503.80 ± (502.44 - 505.15) ms | 494.86 ± (493.91 - 495.80) ms | -1.8% | ✅ |
| runtime.dotnet.exceptions.count | 0 ± (0 - 0) | 0 ± (0 - 0) | +0.0% | ✅ |
| runtime.dotnet.mem.committed | 38.01 ± (37.99 - 38.04) MB | 38.16 ± (38.13 - 38.19) MB | +0.4% | ✅⬆️ |
| runtime.dotnet.threads.count | 27 ± (27 - 27) | 27 ± (27 - 27) | +0.8% | ✅⬆️ |
HttpMessageHandler
| Metric | Master (Mean ± 95% CI) | Current (Mean ± 95% CI) | Change | Status |
|---|---|---|---|---|
| .NET Framework 4.8 - Baseline | ||||
| duration | 204.99 ± (204.93 - 205.88) ms | 216.85 ± (216.40 - 217.39) ms | +5.8% | ❌⬆️ |
| .NET Framework 4.8 - Bailout | ||||
| duration | 209.74 ± (209.44 - 210.44) ms | 219.25 ± (219.17 - 220.25) ms | +4.5% | ✅⬆️ |
| .NET Framework 4.8 - CallTarget+Inlining+NGEN | ||||
| duration | 1238.61 ± (1237.15 - 1243.33) ms | 1292.65 ± (1295.71 - 1304.29) ms | +4.4% | ✅⬆️ |
| .NET Core 3.1 - Baseline | ||||
| process.internal_duration_ms | 196.67 ± (196.24 - 197.10) ms | 207.15 ± (206.75 - 207.55) ms | +5.3% | ✅⬆️ |
| process.time_to_main_ms | 86.31 ± (86.02 - 86.60) ms | 92.15 ± (91.78 - 92.51) ms | +6.8% | ✅⬆️ |
| runtime.dotnet.exceptions.count | 3 ± (3 - 3) | 3 ± (3 - 3) | +0.0% | ✅ |
| runtime.dotnet.mem.committed | 16.15 ± (16.12 - 16.18) MB | 16.09 ± (16.07 - 16.11) MB | -0.4% | ✅ |
| runtime.dotnet.threads.count | 20 ± (19 - 20) | 20 ± (20 - 20) | +1.4% | ✅⬆️ |
| .NET Core 3.1 - Bailout | ||||
| process.internal_duration_ms | 196.83 ± (196.36 - 197.29) ms | 206.75 ± (206.31 - 207.18) ms | +5.0% | ✅⬆️ |
| process.time_to_main_ms | 87.47 ± (87.24 - 87.70) ms | 93.39 ± (93.14 - 93.63) ms | +6.8% | ✅⬆️ |
| runtime.dotnet.exceptions.count | 3 ± (3 - 3) | 3 ± (3 - 3) | +0.0% | ✅ |
| runtime.dotnet.mem.committed | 16.15 ± (16.12 - 16.17) MB | 16.16 ± (16.14 - 16.18) MB | +0.1% | ✅⬆️ |
| runtime.dotnet.threads.count | 21 ± (20 - 21) | 21 ± (21 - 21) | +0.9% | ✅⬆️ |
| .NET Core 3.1 - CallTarget+Inlining+NGEN | ||||
| process.internal_duration_ms | 390.74 ± (389.32 - 392.16) ms | 407.49 ± (406.02 - 408.96) ms | +4.3% | ✅⬆️ |
| process.time_to_main_ms | 551.71 ± (550.51 - 552.92) ms | 576.87 ± (575.22 - 578.52) ms | +4.6% | ✅⬆️ |
| runtime.dotnet.exceptions.count | 3 ± (3 - 3) | 3 ± (3 - 3) | +0.0% | ✅ |
| runtime.dotnet.mem.committed | 58.97 ± (58.75 - 59.19) MB | 59.82 ± (59.75 - 59.88) MB | +1.4% | ✅⬆️ |
| runtime.dotnet.threads.count | 30 ± (30 - 30) | 30 ± (30 - 30) | +1.2% | ✅⬆️ |
| .NET 6 - Baseline | ||||
| process.internal_duration_ms | 203.15 ± (202.78 - 203.52) ms | 210.90 ± (210.34 - 211.46) ms | +3.8% | ✅⬆️ |
| process.time_to_main_ms | 76.14 ± (75.92 - 76.36) ms | 80.36 ± (80.07 - 80.65) ms | +5.5% | ✅⬆️ |
| runtime.dotnet.exceptions.count | 4 ± (4 - 4) | 4 ± (4 - 4) | +0.0% | ✅ |
| runtime.dotnet.mem.committed | 16.55 ± (16.52 - 16.57) MB | 16.35 ± (16.32 - 16.38) MB | -1.2% | ✅ |
| runtime.dotnet.threads.count | 19 ± (19 - 19) | 19 ± (19 - 20) | +1.4% | ✅⬆️ |
| .NET 6 - Bailout | ||||
| process.internal_duration_ms | 203.41 ± (203.07 - 203.76) ms | 210.12 ± (209.61 - 210.63) ms | +3.3% | ✅⬆️ |
| process.time_to_main_ms | 78.01 ± (77.83 - 78.19) ms | 81.32 ± (81.09 - 81.56) ms | +4.2% | ✅⬆️ |
| runtime.dotnet.exceptions.count | 4 ± (4 - 4) | 4 ± (4 - 4) | +0.0% | ✅ |
| runtime.dotnet.mem.committed | 16.53 ± (16.51 - 16.54) MB | 16.41 ± (16.38 - 16.44) MB | -0.7% | ✅ |
| runtime.dotnet.threads.count | 20 ± (20 - 20) | 21 ± (20 - 21) | +1.7% | ✅⬆️ |
| .NET 6 - CallTarget+Inlining+NGEN | ||||
| process.internal_duration_ms | 584.38 ± (582.15 - 586.61) ms | 581.39 ± (579.09 - 583.70) ms | -0.5% | ✅ |
| process.time_to_main_ms | 562.58 ± (561.31 - 563.85) ms | 590.08 ± (589.00 - 591.16) ms | +4.9% | ✅⬆️ |
| runtime.dotnet.exceptions.count | 4 ± (4 - 4) | 4 ± (4 - 4) | +0.0% | ✅ |
| runtime.dotnet.mem.committed | 61.61 ± (61.52 - 61.70) MB | 61.59 ± (61.51 - 61.68) MB | -0.0% | ✅ |
| runtime.dotnet.threads.count | 31 ± (31 - 31) | 31 ± (31 - 31) | +0.1% | ✅⬆️ |
| .NET 8 - Baseline | ||||
| process.internal_duration_ms | 200.95 ± (200.57 - 201.33) ms | 212.39 ± (211.90 - 212.89) ms | +5.7% | ✅⬆️ |
| process.time_to_main_ms | 74.52 ± (74.22 - 74.82) ms | 80.50 ± (80.26 - 80.75) ms | +8.0% | ✅⬆️ |
| runtime.dotnet.exceptions.count | 4 ± (4 - 4) | 4 ± (4 - 4) | +0.0% | ✅ |
| runtime.dotnet.mem.committed | 11.84 ± (11.81 - 11.86) MB | 11.82 ± (11.80 - 11.84) MB | -0.1% | ✅ |
| runtime.dotnet.threads.count | 19 ± (18 - 19) | 19 ± (19 - 19) | +2.3% | ✅⬆️ |
| .NET 8 - Bailout | ||||
| process.internal_duration_ms | 201.31 ± (200.89 - 201.72) ms | 211.62 ± (211.13 - 212.12) ms | +5.1% | ✅⬆️ |
| process.time_to_main_ms | 76.04 ± (75.85 - 76.23) ms | 81.91 ± (81.61 - 82.21) ms | +7.7% | ✅⬆️ |
| runtime.dotnet.exceptions.count | 4 ± (4 - 4) | 4 ± (4 - 4) | +0.0% | ✅ |
| runtime.dotnet.mem.committed | 11.85 ± (11.82 - 11.87) MB | 11.85 ± (11.82 - 11.87) MB | -0.0% | ✅ |
| runtime.dotnet.threads.count | 20 ± (20 - 20) | 20 ± (20 - 20) | +1.7% | ✅⬆️ |
| .NET 8 - CallTarget+Inlining+NGEN | ||||
| process.internal_duration_ms | 511.03 ± (505.70 - 516.35) ms | 533.97 ± (527.27 - 540.67) ms | +4.5% | ✅⬆️ |
| process.time_to_main_ms | 514.59 ± (513.52 - 515.67) ms | 542.82 ± (541.86 - 543.77) ms | +5.5% | ✅⬆️ |
| runtime.dotnet.exceptions.count | 4 ± (4 - 4) | 4 ± (4 - 4) | +0.0% | ✅ |
| runtime.dotnet.mem.committed | 51.34 ± (51.28 - 51.40) MB | 51.53 ± (51.45 - 51.60) MB | +0.4% | ✅⬆️ |
| runtime.dotnet.threads.count | 30 ± (29 - 30) | 30 ± (30 - 30) | +1.0% | ✅⬆️ |
Comparison explanation
Execution-time benchmarks measure the whole time it takes to execute a program, and are intended to measure the one-off costs. Cases where the execution time results for the PR are worse than latest master results are highlighted in **red**. The following thresholds were used for comparing the execution times:
- Welch test with statistical test for significance of 5%
- Only results indicating a difference greater than 5% and 5 ms are considered.
Note that these results are based on a single point-in-time result for each branch. For full results, see the dashboard.
Graphs show the p99 interval based on the mean and StdDev of the test run, as well as the mean value of the run (shown as a diamond below the graph).
Duration charts
FakeDbCommand (.NET Framework 4.8)
gantt
title Execution time (ms) FakeDbCommand (.NET Framework 4.8)
dateFormat x
axisFormat %Q
todayMarker off
section Baseline
This PR (8350) - mean (73ms) : 69, 78
master - mean (72ms) : 69, 75
section Bailout
This PR (8350) - mean (78ms) : 74, 83
master - mean (78ms) : 75, 82
section CallTarget+Inlining+NGEN
This PR (8350) - mean (1,086ms) : 1046, 1126
master - mean (1,090ms) : 1044, 1135
FakeDbCommand (.NET Core 3.1)
gantt
title Execution time (ms) FakeDbCommand (.NET Core 3.1)
dateFormat x
axisFormat %Q
todayMarker off
section Baseline
This PR (8350) - mean (114ms) : 110, 119
master - mean (114ms) : 108, 120
section Bailout
This PR (8350) - mean (112ms) : 107, 116
master - mean (113ms) : 108, 118
section CallTarget+Inlining+NGEN
This PR (8350) - mean (785ms) : 756, 814
master - mean (786ms) : 766, 805
FakeDbCommand (.NET 6)
gantt
title Execution time (ms) FakeDbCommand (.NET 6)
dateFormat x
axisFormat %Q
todayMarker off
section Baseline
This PR (8350) - mean (99ms) : 94, 104
master - mean (98ms) : 95, 102
section Bailout
This PR (8350) - mean (103ms) : 98, 107
master - mean (99ms) : 97, 102
section CallTarget+Inlining+NGEN
This PR (8350) - mean (945ms) : 908, 983
master - mean (949ms) : 915, 982
FakeDbCommand (.NET 8)
gantt
title Execution time (ms) FakeDbCommand (.NET 8)
dateFormat x
axisFormat %Q
todayMarker off
section Baseline
This PR (8350) - mean (96ms) : 93, 98
master - mean (101ms) : 96, 106
section Bailout
This PR (8350) - mean (97ms) : 95, 99
master - mean (99ms) : 95, 104
section CallTarget+Inlining+NGEN
This PR (8350) - mean (822ms) : 781, 862
master - mean (830ms) : 787, 872
HttpMessageHandler (.NET Framework 4.8)
gantt
title Execution time (ms) HttpMessageHandler (.NET Framework 4.8)
dateFormat x
axisFormat %Q
todayMarker off
section Baseline
This PR (8350) - mean (217ms) : 212, 222
master - mean (205ms) : 200, 211
section Bailout
This PR (8350) - mean (220ms) : 214, 226
master - mean (210ms) : 205, 215
section CallTarget+Inlining+NGEN
This PR (8350) - mean (1,300ms) : 1235, 1365
master - mean (1,240ms) : 1194, 1286
HttpMessageHandler (.NET Core 3.1)
gantt
title Execution time (ms) HttpMessageHandler (.NET Core 3.1)
dateFormat x
axisFormat %Q
todayMarker off
section Baseline
This PR (8350) - mean (310ms) : 305, 316
master - mean (293ms) : 285, 301
section Bailout
This PR (8350) - mean (311ms) : 305, 316
master - mean (294ms) : 288, 301
section CallTarget+Inlining+NGEN
This PR (8350) - mean (1,027ms) : 1003, 1051
master - mean (984ms) : 958, 1010
HttpMessageHandler (.NET 6)
gantt
title Execution time (ms) HttpMessageHandler (.NET 6)
dateFormat x
axisFormat %Q
todayMarker off
section Baseline
This PR (8350) - mean (302ms) : 295, 309
master - mean (289ms) : 284, 294
section Bailout
This PR (8350) - mean (301ms) : 295, 308
master - mean (291ms) : 287, 296
section CallTarget+Inlining+NGEN
This PR (8350) - mean (1,212ms) : 1166, 1259
master - mean (1,180ms) : 1144, 1216
HttpMessageHandler (.NET 8)
gantt
title Execution time (ms) HttpMessageHandler (.NET 8)
dateFormat x
axisFormat %Q
todayMarker off
section Baseline
This PR (8350) - mean (304ms) : 293, 315
master - mean (286ms) : 280, 291
section Bailout
This PR (8350) - mean (305ms) : crit, 298, 312
master - mean (288ms) : 283, 293
section CallTarget+Inlining+NGEN
This PR (8350) - mean (1,125ms) : 1026, 1224
master - mean (1,062ms) : 989, 1135
31eb9a6 to
dafcf50
Compare
dafcf50 to
59a8b4a
Compare
andrewlock
left a comment
There was a problem hiding this comment.
If we're sure this works where you have the same container used on multiple tests then looks good, but that's the scenario we should test IMO 🙂
| { | ||
| [CollectionDefinition(Name)] | ||
|
|
||
| public class AerospikeCollection : ICollectionFixture<AerospikeFixture> |
There was a problem hiding this comment.
This feels... weird 😅 I hate the loosey-goosey ness of this wiring up. But that's just xunit for you 🤷♂️
| <PackageReference Include="System.Collections.Immutable" Version="6.0.0" /> | ||
|
|
||
| <PackageReference Include="Testcontainers" Version="3.6.0" /> | ||
| <PackageReference Include="Testcontainers" Version="4.11.0" /> |
There was a problem hiding this comment.
Any breaking changes we actually care about out of interest?
There was a problem hiding this comment.
The biggest one that I noticed was that they appeared to go from Docker.Dotnet to their own Docker.Dotnet.Enhanced which required the Newtonsoft.Json dependency
The other changes seemed quite small from what I found
| _resources = await InitializeResources().ConfigureAwait(false); | ||
| } | ||
|
|
||
| // Do not implement, the ContainersRegistry is responsible for disposing the containers |
There was a problem hiding this comment.
Hmmm, as per the original PR:
Because fixtures are not singleton, the ContainersRegistry is used to store the objects across multiple fixtures.
that seems like it would still be an issue? 🤔 Should we just make sure to call Dispose on the registry from the custom test helper before it shuts down? 🤔
FWIW, leaving the containers running may have been intentional, for faster inner-loop dev 😄
There was a problem hiding this comment.
Realised that the original was using IClassFixture not IContainerFixture but still, we should prob check that they Are singletons in this case...
There was a problem hiding this comment.
Thanks I'll look into this
There was a problem hiding this comment.
Okay from what I can tell running it locally with this and with my other PRs #8353 and #8430 it seems to be the case that they are all singletons
I think leaving the containers running was intentional
I guess that is something that we could come back to if it proves to be beneficial in the future, I guess it matches our current behavior in CI and local dev where the containers are spun up and left running
59a8b4a to
dca3189
Compare
4309c8a to
bea5df3
Compare
bea5df3 to
36b956d
Compare
Summary of changes
This upgrades
Testcontainersto v4 in preparation for more migration of integration tests to use this over normal docker compose files.This also removes the
ContainersRegistryand instead just uses xUnit'sICollectionFixtureas previously the actual containers were not being disposed of (in CI they do get cleaned up after the job ends from my understanding) but locally the container would just stay running.Reason for change
I find it tedious to have to do a
docker compose up.... every time that I want to run integration tests locally I would much rather just get to a point where we just can run the test and let the infrastructure handle everything else. This sets us up to start doing that.Implementation details
Testcontainersversion, fixed build errors / API changesNewtonsoft.Jsonreference toTestHelpers.AutoInstrumentationas it was complaining that it wasn't thereAerospikeTeststo be the new wayTest coverage
Ran locally before/after there are no differences (outside of the fact that the container is properly disposed now)
Other details
I'll be plugging away at the other integrations