public function testDelete() { $this->connection->deleteSubscription(Argument::withEntry('foo', 'bar'))->willReturn(null)->shouldBeCalledTimes(1); $subscription = new Subscription($this->connection->reveal(), 'subscription-name', 'topic-name', 'project-id'); $res = $subscription->delete(['foo' => 'bar']); $this->assertNull($res); }