Skip to content

Commit

Permalink
test: fix specs for run command
Browse files Browse the repository at this point in the history
  • Loading branch information
rafaelgomesxyz committed Aug 21, 2024
1 parent d9f4ebb commit fcbfc73
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions lib/command/run.rb
Original file line number Diff line number Diff line change
Expand Up @@ -243,7 +243,7 @@ def update_runner_workload # rubocop:disable Metrics/CyclomaticComplexity, Metri

step("Updating runner workload '#{runner_workload}'") do
# Update runner workload
@expected_deployed_version = cp.cron_workload_deployed_version(runner_workload) + 1
@expected_deployed_version = (cp.cron_workload_deployed_version(runner_workload) || 0) + 1
cp.apply_hash("kind" => "workload", "name" => runner_workload, "spec" => spec)
end
end
Expand All @@ -256,7 +256,7 @@ def wait_for_runner_workload_deploy

def wait_for_runner_workload_update
step("Waiting for runner workload '#{runner_workload}' to be updated", retry_on_failure: true) do
cp.cron_workload_deployed_version(runner_workload) >= expected_deployed_version
(cp.cron_workload_deployed_version(runner_workload) || 0) >= expected_deployed_version
end
end

Expand Down

0 comments on commit fcbfc73

Please sign in to comment.