From 7eff058bd7a3392e01bb855b2d29723a2c1f709b Mon Sep 17 00:00:00 2001 From: Dave Supplee Date: Wed, 23 Nov 2016 23:53:11 -0500 Subject: [PATCH] use resourceName instead of projectIds --- src/Logging/Logger.php | 2 +- tests/unit/Logging/LoggerTest.php | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/src/Logging/Logger.php b/src/Logging/Logger.php index 3942555ed69f..aa1ae76de187 100644 --- a/src/Logging/Logger.php +++ b/src/Logging/Logger.php @@ -152,7 +152,7 @@ public function entries(array $options = []) $logNameFilter = "logName = $this->formattedName"; $options += [ 'pageToken' => null, - 'projectIds' => [$this->projectId], + 'resourceNames' => ["projects/$this->projectId"], 'filter' => isset($options['filter']) ? $options['filter'] .= " AND $logNameFilter" : $logNameFilter diff --git a/tests/unit/Logging/LoggerTest.php b/tests/unit/Logging/LoggerTest.php index d0a05f9eb4d1..69441ddd3fad 100644 --- a/tests/unit/Logging/LoggerTest.php +++ b/tests/unit/Logging/LoggerTest.php @@ -65,7 +65,7 @@ public function testGetsEntriesWithNoResults() ]; $this->connection->listEntries($options + [ 'pageToken' => null, - 'projectIds' => [$this->projectId], + 'resourceNames' => ["projects/$this->projectId"], 'filter' => "logName = $this->formattedName" ]) ->willReturn([]) @@ -122,7 +122,7 @@ public function testGetsEntriesWithAdditionalFilter() $filter = 'textPayload = "hello world"'; $this->connection->listEntries([ 'pageToken' => null, - 'projectIds' => [$this->projectId], + 'resourceNames' => ["projects/$this->projectId"], 'filter' => $filter . " AND logName = $this->formattedName" ]) ->willReturn([])