Skip to content
This repository has been archived by the owner on Dec 7, 2019. It is now read-only.

Commit

Permalink
Merge branch 'hotfix/google-api-urls'
Browse files Browse the repository at this point in the history
Close #12
  • Loading branch information
mwillbanks committed Oct 14, 2015
2 parents 4a42ecc + 06dc166 commit c2ebc3e
Show file tree
Hide file tree
Showing 8 changed files with 26 additions and 9 deletions.
22 changes: 22 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
# Changelog

All notable changes to this project will be documented in this file, in reverse chronological order by release.

## 1.0.3 - TBD

### Added

- Nothing.

### Deprecated

- Nothing.

### Removed

- Nothing.

### Fixed

- [#12](https://github.com/zendframework/ZendService_Google_Gcm/pull/12) -
Updated GCM URL.
Original file line number Diff line number Diff line change
Expand Up @@ -19,5 +19,4 @@
*/
class InvalidArgumentException extends \InvalidArgumentException
{

}
1 change: 0 additions & 1 deletion library/ZendService/Google/Exception/RuntimeException.php
Original file line number Diff line number Diff line change
Expand Up @@ -19,5 +19,4 @@
*/
class RuntimeException extends \RuntimeException
{

}
2 changes: 1 addition & 1 deletion library/ZendService/Google/Gcm/Client.php
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@ class Client
/**
* @const string Server URI
*/
const SERVER_URI = 'https://android.googleapis.com/gcm/send';
const SERVER_URI = 'https://gcm-http.googleapis.com/gcm/send';

/**
* @var Zend\Http\Client
Expand Down
2 changes: 1 addition & 1 deletion library/ZendService/Google/Gcm/Response.php
Original file line number Diff line number Diff line change
Expand Up @@ -225,7 +225,7 @@ protected function correlate()
$results = $this->results;
if ($this->message && $results) {
$ids = $this->message->getRegistrationIds();
while($id = array_shift($ids)) {
while ($id = array_shift($ids)) {
$results[$id] = array_shift($results);
}
}
Expand Down
2 changes: 1 addition & 1 deletion tests/Bootstrap.php
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@
/*
* Set error reporting to the level to which Zend Framework code must comply.
*/
error_reporting( E_ALL | E_STRICT );
error_reporting(E_ALL | E_STRICT);

$phpUnitVersion = PHPUnit_Runner_Version::id();
if ('@package_version@' !== $phpUnitVersion && version_compare($phpUnitVersion, '3.5.0', '<')) {
Expand Down
3 changes: 1 addition & 2 deletions tests/ZendService/Google/Gcm/ClientTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -28,15 +28,14 @@
*/
class ClientTest extends \PHPUnit_Framework_TestCase
{

protected $httpAdapter;
protected $httpClient;
protected $gcmClient;
protected $message;

protected function _createJSONResponse($id, $success, $failure, $ids, $results)
{
return json_encode(array(
return json_encode(array(
'multicast_id' => $id,
'success' => $success,
'failure' => $failure,
Expand Down
2 changes: 0 additions & 2 deletions tests/ZendService/Google/Gcm/MessageTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,6 @@
*/
class MessageTest extends \PHPUnit_Framework_TestCase
{

protected $validRegistrationIds = array('1234567890', '0987654321');
protected $validData = array('key' => 'value', 'key2' => array('value'));

Expand Down Expand Up @@ -157,5 +156,4 @@ public function testExpectedDryRunBehavior()
$this->assertEquals($this->m->getDryRun(), false);
$this->assertNotContains('dry_run', $this->m->toJson());
}

}

0 comments on commit c2ebc3e

Please sign in to comment.