Skip to content

Commit 06ed423

Browse files
Add support for Travis CI
Uses Travis to run tests against PHP 5.3, 5.4 and 5.5.
1 parent f38f6c9 commit 06ed423

File tree

3 files changed

+9
-3
lines changed

3 files changed

+9
-3
lines changed

.travis.yml

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

33
php:
4+
# Can't test against 5.2; openssl is not available:
5+
# http://docs.travis-ci.com/user/languages/php/#PHP-installation
6+
- 5.3
7+
- 5.4
48
- 5.5
59

6-
before_script:
7-
- curl -s http://getcomposer.org/installer | php
8-
- php composer.phar install
10+
before_script:
11+
- composer install
912

1013
script:
1114
- cd tests ; phpunit .

tests/pagespeed/PageSpeedTest.php

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -25,6 +25,7 @@ public function __construct() {
2525
}
2626

2727
public function testPageSpeed() {
28+
$this->checkToken();
2829
$psapi = $this->service->pagespeedapi;
2930
$result = $psapi->runpagespeed('http://code.google.com');
3031
$this->assertArrayHasKey('kind', $result);

tests/plus/PlusTest.php

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -35,6 +35,7 @@ public function __construct() {
3535
}
3636

3737
public function testGetPerson() {
38+
$this->checkToken();
3839
$person = $this->plus->people->get("118051310819094153327");
3940
$this->assertArrayHasKey('kind', $person);
4041
$this->assertArrayHasKey('displayName', $person);
@@ -43,6 +44,7 @@ public function testGetPerson() {
4344
}
4445

4546
public function testListActivities() {
47+
$this->checkToken();
4648
$activities = $this->plus->activities
4749
->listActivities("118051310819094153327", "public");
4850

0 commit comments

Comments
 (0)