Rewritten part of saucelabs runner to JS