Skip to content

Commit 161335d

Browse files
committed
Add missing simple test for authentication with Client::AUTH_URL_CLIENT_ID, extended Travis-CI testing
1 parent c633cc7 commit 161335d

File tree

2 files changed

+14
-1
lines changed

2 files changed

+14
-1
lines changed

.travis.yml

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,13 @@
11
language: php
22

33
php:
4+
- 5.3.3
45
- 5.3
56
- 5.4
7+
- 5.5
68

79
before_script:
8-
- composer install --dev
10+
- composer install --dev --prefer-source
911

1012
script:
1113
- phpunit --coverage-text

test/Github/Tests/ClientTest.php

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -55,6 +55,17 @@ public function shouldAuthenticateUsingUrlToken()
5555
$this->assertInstanceOf('Github\HttpClient\HttpClient', $client->getHttpClient());
5656
}
5757

58+
/**
59+
* @test
60+
*/
61+
public function shouldAuthenticateUsingUrlClientId()
62+
{
63+
$client = new Client();
64+
$client->authenticate('client_id', 'client_secret', Client::AUTH_URL_CLIENT_ID);
65+
66+
$this->assertInstanceOf('Github\HttpClient\HttpClient', $client->getHttpClient());
67+
}
68+
5869
/**
5970
* @test
6071
*/

0 commit comments

Comments
 (0)