Commit 6520d3a
authored
Fix tests (#322)
* fix(tests): Use architecture-specific streams in coordinator tests
Fix 7 failing tests in test_self_contained_coordinator_memtier.py by:
- Adding messages to arch-specific streams instead of base stream
- Fixing consumer group creation parameters (arch and id)
- Updating assertions to check arch-specific streams
This aligns tests with the arch-specific stream routing implemented
in the coordinator, which reads from streams like:
- oss:api:gh/redis/redis/builds:amd64 (for amd64)
- oss:api:gh/redis/redis/builds:arm64 (for arm64)
Fixes:
- test_self_contained_coordinator_dockerhub_preload
- test_self_contained_coordinator_dockerhub
- test_self_contained_coordinator_dockerhub_iothreads
- test_self_contained_coordinator_dockerhub_valkey
- test_dockerhub_via_cli
- test_dockerhub_via_cli_airgap
- test_self_contained_coordinator_duplicated_ts
* style: Format test file with black
Apply black formatting to test_self_contained_coordinator_memtier.py
to comply with CI code style checks.
* style: Format runner.py with black
Apply black formatting to runner.py for FLUSHALL changes
from PR #320 to comply with CI code style checks.
* fix(runner): Skip validation for untested operation types
Improve metric validation to skip operation-specific metrics when those
operations are not in the tested-commands list. For example, a SET-only
test (--ratio 1:0) will now skip validation of Gets.Ops/sec metric,
which would legitimately be 0.
This fixes CI test failures where SET-only tests were failing validation
because Gets.Ops/sec was 0 (below the 10 QPS threshold).
The validation now:
1. Checks benchmark_config for 'tested-commands' list
2. Skips metrics for operation types (gets, sets, hgets, etc.) that
are not in the tested-commands list
3. Still validates metrics for operations that are actually being tested
* fix(tests): Add git_version to benchmark stream requests
Add git_version parameter when calling generate_benchmark_stream_request
in tests. This ensures version information is propagated through the stream
to the coordinator, allowing by.version keys to be created in Redis.
Without this, the tests expect by.version keys to exist but they were never
created because artifact_version was None in the data export logic.
Fixes test assertions that check for:
- ci.benchmarks.redis/.../by.version/{version}/benchmark_end/.../memory_maxmemory
Tests fixed:
- test_self_contained_coordinator_dockerhub_preload
- test_self_contained_coordinator_dockerhub
- test_self_contained_coordinator_dockerhub_iothreads
- test_self_contained_coordinator_dockerhub_valkey
- test_self_contained_coordinator_duplicated_ts
* fix(cli): Extract git_version from Docker image tag
- Add regex-based version extraction from image names like 'redis:7.4.0' or 'valkey/valkey:7.2.6-bookworm'
- Pass extracted git_version to generate_benchmark_stream_request()
- Enables by.version Redis TimeSeries keys to be created for CLI-triggered tests
- Fixes test_dockerhub_via_cli and test_dockerhub_via_cli_airgap assertion failures
* style: Format cli.py with black
Apply black formatting to comply with CI code style checks.
* debug: Add logging to diagnose artifact_version issue
* debug: Add print statements to track artifact_version value
* style: Format runner.py with black
* fix: Include running_platform in by.version key paths
The export_redis_metrics function creates keys with the format:
{prefix}/{test}/{by_variant}/benchmark_end/{running_platform}/{setup}/{metric}
But tests were expecting keys without running_platform:
{prefix}/{test}/{by_variant}/benchmark_end/{setup}/{metric}
This fixes all 6 failing tests by adding running_platform to the expected key format.
Also removes debug print statements that helped diagnose the issue.
* fix: Add JSON module support and correct test metadata
This commit fixes stats validation errors:
1. Add JSON module commands to commands.json:
- JSON.GET: Return value at path in JSON serialized form
- JSON.SET: Sets or updates JSON value at a path
2. Add 'json' group to groups.json with JSON commands
3. Fix test-suite metadata issues:
- memtier_benchmark-playbook-rate-limiting-lua-100k-sessions.yml:
Remove 'bitmap' from tested-groups (only scripting is tested via EVAL)
- memtier_benchmark-playbook-realtime-analytics-membership.yml:
Add 'sunion' to tested-commands (SUNION command was used but not listed)
- memtier_benchmark-playbook-realtime-analytics-membership-pipeline-10.yml:
Add 'sunion' to tested-commands
These changes resolve all stats validation errors in CI.
* fix missing quote from test case memtier_benchmark-1Mkeys-string-set-with-ex-100B-pipeline-10.yml1 parent 8a23ac1 commit 6520d3a
File tree
9 files changed
+19863
-19751
lines changed- redis_benchmarks_specification
- __cli__
- __runner__
- test-suites
- utils/tests
9 files changed
+19863
-19751
lines changedLarge diffs are not rendered by default.
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1 | 1 | | |
2 | 2 | | |
3 | | - | |
4 | | - | |
| 3 | + | |
| 4 | + | |
5 | 5 | | |
6 | 6 | | |
7 | | - | |
8 | | - | |
| 7 | + | |
| 8 | + | |
9 | 9 | | |
10 | 10 | | |
11 | | - | |
12 | | - | |
| 11 | + | |
| 12 | + | |
13 | 13 | | |
14 | 14 | | |
15 | | - | |
16 | | - | |
| 15 | + | |
| 16 | + | |
17 | 17 | | |
18 | 18 | | |
19 | | - | |
20 | | - | |
| 19 | + | |
| 20 | + | |
21 | 21 | | |
22 | 22 | | |
23 | | - | |
24 | | - | |
| 23 | + | |
| 24 | + | |
25 | 25 | | |
26 | 26 | | |
27 | | - | |
28 | | - | |
| 27 | + | |
| 28 | + | |
29 | 29 | | |
| 30 | + | |
| 31 | + | |
| 32 | + | |
| 33 | + | |
30 | 34 | | |
31 | | - | |
32 | | - | |
| 35 | + | |
| 36 | + | |
33 | 37 | | |
34 | 38 | | |
35 | | - | |
36 | | - | |
| 39 | + | |
| 40 | + | |
37 | 41 | | |
38 | 42 | | |
39 | | - | |
40 | | - | |
| 43 | + | |
| 44 | + | |
41 | 45 | | |
42 | 46 | | |
43 | | - | |
44 | | - | |
| 47 | + | |
| 48 | + | |
45 | 49 | | |
46 | 50 | | |
47 | | - | |
48 | | - | |
| 51 | + | |
| 52 | + | |
49 | 53 | | |
50 | 54 | | |
51 | | - | |
52 | | - | |
| 55 | + | |
| 56 | + | |
53 | 57 | | |
54 | 58 | | |
55 | | - | |
56 | | - | |
| 59 | + | |
| 60 | + | |
57 | 61 | | |
58 | 62 | | |
59 | | - | |
60 | | - | |
| 63 | + | |
| 64 | + | |
61 | 65 | | |
62 | 66 | | |
63 | | - | |
64 | | - | |
| 67 | + | |
| 68 | + | |
65 | 69 | | |
66 | 70 | | |
67 | | - | |
68 | | - | |
| 71 | + | |
| 72 | + | |
69 | 73 | | |
70 | | - | |
| 74 | + | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
80 | 80 | | |
81 | 81 | | |
82 | 82 | | |
| 83 | + | |
| 84 | + | |
| 85 | + | |
| 86 | + | |
| 87 | + | |
| 88 | + | |
| 89 | + | |
| 90 | + | |
| 91 | + | |
| 92 | + | |
| 93 | + | |
| 94 | + | |
| 95 | + | |
| 96 | + | |
| 97 | + | |
| 98 | + | |
83 | 99 | | |
84 | 100 | | |
85 | 101 | | |
| |||
96 | 112 | | |
97 | 113 | | |
98 | 114 | | |
99 | | - | |
| 115 | + | |
100 | 116 | | |
101 | 117 | | |
102 | 118 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
175 | 175 | | |
176 | 176 | | |
177 | 177 | | |
178 | | - | |
| 178 | + | |
179 | 179 | | |
180 | 180 | | |
181 | 181 | | |
182 | 182 | | |
183 | 183 | | |
184 | 184 | | |
| 185 | + | |
| 186 | + | |
| 187 | + | |
| 188 | + | |
| 189 | + | |
| 190 | + | |
| 191 | + | |
185 | 192 | | |
186 | 193 | | |
187 | 194 | | |
| |||
219 | 226 | | |
220 | 227 | | |
221 | 228 | | |
| 229 | + | |
| 230 | + | |
| 231 | + | |
| 232 | + | |
| 233 | + | |
| 234 | + | |
| 235 | + | |
| 236 | + | |
| 237 | + | |
| 238 | + | |
| 239 | + | |
| 240 | + | |
| 241 | + | |
| 242 | + | |
| 243 | + | |
| 244 | + | |
| 245 | + | |
| 246 | + | |
| 247 | + | |
| 248 | + | |
| 249 | + | |
| 250 | + | |
| 251 | + | |
222 | 252 | | |
223 | 253 | | |
224 | 254 | | |
| |||
2680 | 2710 | | |
2681 | 2711 | | |
2682 | 2712 | | |
2683 | | - | |
2684 | | - | |
| 2713 | + | |
| 2714 | + | |
| 2715 | + | |
| 2716 | + | |
| 2717 | + | |
| 2718 | + | |
| 2719 | + | |
2685 | 2720 | | |
2686 | 2721 | | |
2687 | 2722 | | |
2688 | 2723 | | |
2689 | | - | |
| 2724 | + | |
| 2725 | + | |
| 2726 | + | |
2690 | 2727 | | |
2691 | 2728 | | |
2692 | 2729 | | |
| |||
3033 | 3070 | | |
3034 | 3071 | | |
3035 | 3072 | | |
3036 | | - | |
3037 | | - | |
| 3073 | + | |
| 3074 | + | |
| 3075 | + | |
| 3076 | + | |
| 3077 | + | |
| 3078 | + | |
| 3079 | + | |
3038 | 3080 | | |
3039 | 3081 | | |
3040 | 3082 | | |
| |||
Lines changed: 1 addition & 1 deletion
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
12 | 12 | | |
13 | 13 | | |
14 | 14 | | |
15 | | - | |
| 15 | + | |
16 | 16 | | |
17 | 17 | | |
18 | 18 | | |
| |||
Lines changed: 0 additions & 1 deletion
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
34 | 34 | | |
35 | 35 | | |
36 | 36 | | |
37 | | - | |
38 | 37 | | |
39 | 38 | | |
40 | 39 | | |
| |||
Lines changed: 1 addition & 0 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
35 | 35 | | |
36 | 36 | | |
37 | 37 | | |
| 38 | + | |
38 | 39 | | |
39 | 40 | | |
40 | 41 | | |
| |||
Lines changed: 1 addition & 0 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
35 | 35 | | |
36 | 36 | | |
37 | 37 | | |
| 38 | + | |
38 | 39 | | |
39 | 40 | | |
40 | 41 | | |
| |||
0 commit comments