@nsshunt/stsrunnerframework 1.0.138 → 1.0.140

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1820,10 +1820,9 @@ class WorkerInstance {
1820
1820
  if (executionProfile) {
1821
1821
  const { iterations, duration, delayBetweenIterations, pauseOnComplete } = executionProfile;
1822
1822
  if (iterations > 0) {
1823
- if (pauseOnComplete === true) {
1824
- cont = __privateGet(this, _GetRunnerIterationById).call(this, runnerId) <= iterations;
1825
- } else {
1826
- cont = __privateGet(this, _GetRunnerIterationById).call(this, runnerId) < iterations;
1823
+ cont = __privateGet(this, _GetRunnerIterationById).call(this, runnerId) < iterations;
1824
+ if (cont === false && pauseOnComplete === true && __privateGet(this, _runners)[runnerId].runner.state === IRunnerState.paused) {
1825
+ cont = true;
1827
1826
  }
1828
1827
  } else if (duration > 0) {
1829
1828
  cont = ((/* @__PURE__ */ new Date()).getTime() - startLoop.getTime()) / 1e3 < duration;