mirror of
https://github.com/valitydev/yandex-tank.git
synced 2024-11-06 10:25:17 +00:00
Fix: more consistent final step for step(...) schedule
This commit is contained in:
parent
c31fda723a
commit
e4bdb4ea67
@ -135,8 +135,12 @@ class Stairway(Composite):
|
||||
Const(minrps + i * increment, duration)
|
||||
for i in xrange(0, n_steps + 1)
|
||||
]
|
||||
if (n_steps + 1) * increment < maxrps:
|
||||
steps.append(Const(maxrps, duration))
|
||||
if increment > 0:
|
||||
if (min_rps + n_steps * increment) < maxrps:
|
||||
steps.append(Const(maxrps, duration))
|
||||
elif increment < 0:
|
||||
if (min_rps + n_steps * increment) > maxrps:
|
||||
steps.append(Const(maxrps, duration))
|
||||
logging.info(steps)
|
||||
super(Stairway, self).__init__(steps)
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user