Commit b5ef07f
committed
refactor(http): use strings.Cut for URL sanitization
Replaces the usage of `strings.IndexByte` with the more idiomatic Go
function `strings.Cut`. This function is specifically designed to split
a string into two parts based on a separator, making the code for
redacting URL query parameters clearer and more expressive.
fix(test): remove parallel execution to fix flaky telemetry tests
The telemetry tests in `withTelemetry_test.go` modify shared global
state related to the metrics collector. Running them with `t.Parallel()`
created a race condition, leading to intermittent test failures.
Removing `t.Parallel()` forces these tests to run sequentially,
eliminating the race condition and stabilizing the test suite. A short
sleep was also added to the reset function to ensure the collector has
sufficient time to shut down before the next test starts.
style(test): align struct field values in multi tenant test
Adjusts code formatting in `multi_tenant_test.go` for better
readability by aligning the values in a struct literal. This is a
purely cosmetic change with no functional impact.1 parent 9614832 commit b5ef07f
3 files changed
Lines changed: 5 additions & 7 deletions
File tree
- commons
- net/http
- tenant-manager/consumer
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
58 | 58 | | |
59 | 59 | | |
60 | 60 | | |
61 | | - | |
62 | | - | |
| 61 | + | |
| 62 | + | |
63 | 63 | | |
64 | 64 | | |
65 | 65 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
550 | 550 | | |
551 | 551 | | |
552 | 552 | | |
| 553 | + | |
553 | 554 | | |
554 | 555 | | |
555 | 556 | | |
| |||
559 | 560 | | |
560 | 561 | | |
561 | 562 | | |
562 | | - | |
563 | 563 | | |
564 | 564 | | |
565 | 565 | | |
| |||
575 | 575 | | |
576 | 576 | | |
577 | 577 | | |
578 | | - | |
579 | 578 | | |
580 | 579 | | |
581 | 580 | | |
| |||
585 | 584 | | |
586 | 585 | | |
587 | 586 | | |
588 | | - | |
589 | 587 | | |
590 | 588 | | |
591 | 589 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
889 | 889 | | |
890 | 890 | | |
891 | 891 | | |
892 | | - | |
893 | | - | |
| 892 | + | |
| 893 | + | |
894 | 894 | | |
895 | 895 | | |
896 | 896 | | |
| |||
0 commit comments