Skip to content

Commit b9af15d

Browse files
committed
ft-orchestration start threshold test at half speed
1 parent 6815bd4 commit b9af15d

File tree

1 file changed

+8
-1
lines changed

1 file changed

+8
-1
lines changed

tools/ft-orchestration/tests/simulation/test_simulation_threshold.py

Lines changed: 8 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -289,7 +289,14 @@ def run_single_test(loops: int, speed: MbpsSpeed) -> tuple[bool, StatisticalRepo
289289
if scenario.test.speed_max is not None
290290
else scenario.requirements.speed * 1000
291291
)
292-
speed_current = speed_max
292+
# start in the middle
293+
speed_current = int((speed_max + speed_min) / 2)
294+
# round up to required accuracy
295+
if speed_current % scenario.test.mbps_accuracy > 0:
296+
speed_current = speed_current + (
297+
scenario.test.mbps_accuracy
298+
- speed_current % scenario.test.mbps_accuracy
299+
)
293300
while True:
294301
# setup log path
295302
current_log_dir = os.path.join(log_dir, str(speed_current))

0 commit comments

Comments
 (0)