What does this MR do?
Fixes randomly failing tests from
commands/single_test.go in a way proposed at https://gitlab.com/gitlab-org/gitlab-runner/merge_requests/683#note_40207766. Replacement for !683 (closed).
Why was this MR needed?
Please look into !683 (closed) for a reference.
Are there points in the code the reviewer needs to double check?
Does this MR meet the acceptance criteria?
Added for this feature/bug
All builds are passing
Branch has no merge conflicts with
master(if you do - rebase it please)