Skip to content

Commit 488c5ca

Browse files
committed
Merge pull request #62 from aik099/saucerest-deletejob-api-call
Adds the "deleteJob" call implementation for SauceLabs REST API
2 parents 9b364dd + 2668202 commit 488c5ca

File tree

1 file changed

+13
-1
lines changed

1 file changed

+13
-1
lines changed

lib/WebDriver/SauceLabs/SauceRest.php

Lines changed: 13 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -59,7 +59,7 @@ public function __construct($userId, $accessKey)
5959
* @param string $requestMethod HTTP request method
6060
* @param string $url URL
6161
* @param mixed $parameters Parameters
62-
*
62+
*
6363
* @return mixed
6464
*
6565
* @see http://saucelabs.com/docs/saucerest
@@ -226,6 +226,18 @@ public function stopJob($jobId)
226226
return $this->execute('PUT', $this->userId . '/jobs/' . $jobId . '/stop');
227227
}
228228

229+
/**
230+
* Delete job: /rest/v1/:userId/jobs/:jobId (DELETE)
231+
*
232+
* @param string $jobId
233+
*
234+
* @return array
235+
*/
236+
public function deleteJob($jobId)
237+
{
238+
return $this->execute('DELETE', $this->userId . '/jobs/' . $jobId);
239+
}
240+
229241
/**
230242
* Get running tunnels for a given user: /rest/v1/:userId/tunnels (GET)
231243
*

0 commit comments

Comments
 (0)