diff --git a/.pubnub.yml b/.pubnub.yml index 2904d491..007d4ac5 100644 --- a/.pubnub.yml +++ b/.pubnub.yml @@ -7,7 +7,9 @@ changelog: date: Oct 22, 2019 changes: - type: improvement - text: Update composer.json package version constraints. + text: Update composer.json package version constraints + - type: improvement + text: Update .travis.yml to run tests for PHP versions 7.2 and 7.3 - version: 4.1.4 date: Oct 18, 2019 changes: diff --git a/.travis.yml b/.travis.yml index 92dcde2a..59149df0 100644 --- a/.travis.yml +++ b/.travis.yml @@ -1,10 +1,12 @@ language: php -dist: trusty +dist: xenial sudo: false php: - 5.6 - 7.0 - 7.1 + - 7.2 + - 7.3 install: - composer self-update && composer --version - composer install --prefer-dist diff --git a/CHANGELOG.md b/CHANGELOG.md index 91a17d57..7fcb7897 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,7 +1,8 @@ ## [v4.1.5](https://github.com/pubnub/php/tree/v4.1.5) October-22-2019 -- ⭐Update composer.json package version constraints. +- ⭐Update composer.json package version constraints +- ⭐Update .travis.yml to run tests for PHP versions 7.2 and 7.3 ## [v4.1.4](https://github.com/pubnub/php/tree/v4.1.4) October-18-2019 diff --git a/src/PubNub/Endpoints/Presence/WhereNow.php b/src/PubNub/Endpoints/Presence/WhereNow.php index f636a5e2..e438607e 100644 --- a/src/PubNub/Endpoints/Presence/WhereNow.php +++ b/src/PubNub/Endpoints/Presence/WhereNow.php @@ -8,6 +8,7 @@ use PubNub\Exceptions\PubNubValidationException; use PubNub\Models\Consumer\Presence\PNWhereNowResult; use PubNub\PubNub; +use PubNub\PubNubUtil; class WhereNow extends Endpoint @@ -73,7 +74,7 @@ public function buildPath() { return sprintf(WhereNow::PATH, $this->pubnub->getConfiguration()->getSubscribeKey(), - $this->uuid + PubNubUtil::urlEncode($this->uuid) ); } diff --git a/tests/integrational/HereNowTest.php b/tests/integrational/HereNowTest.php index 5875f1c1..2022accf 100644 --- a/tests/integrational/HereNowTest.php +++ b/tests/integrational/HereNowTest.php @@ -2,6 +2,7 @@ namespace Tests\Integrational; +use Countable; use PubNub\Endpoints\Presence\HereNow; use PubNub\Exceptions\PubNubValidationException; use RawTransport; @@ -129,7 +130,7 @@ public function testMultipleChannelWithoutStateUUIDs() $this->assertEquals($response->getChannels()[0]->getChannelName(), "game1"); $this->assertEquals($response->getChannels()[0]->getOccupancy(), 1); - $this->assertEquals(count($response->getChannels()[0]->getOccupants()), null); + $this->assertEquals(is_array($response->getChannels()[0]->getOccupants()) , false); } /** diff --git a/tests/integrational/HistoryTest.php b/tests/integrational/HistoryTest.php index 7647419e..dfec02e0 100644 --- a/tests/integrational/HistoryTest.php +++ b/tests/integrational/HistoryTest.php @@ -151,7 +151,7 @@ public function testEncryptedSuccess() $this->assertEquals(count($response->getMessages()), 3); - $this->assertEquals(count($response->getMessages()[0]->getTimetoken()), null); + $this->assertEquals($response->getMessages()[0]->getTimetoken(), NULL); $this->assertEquals($response->getMessages()[0]->getEntry()[0], "m1"); $this->assertEquals($response->getMessages()[0]->getEntry()[1], "m2"); $this->assertEquals($response->getMessages()[0]->getEntry()[2], "m3");