public function test_noRequestsWhenIterating() { $resultsReturned = false; $collection = Braintree\Transaction::search([Braintree\TransactionSearch::billingFirstName()->is('thisnameisnotreal')]); foreach ($collection as $transaction) { $resultsReturned = true; break; } $this->assertSame(0, $collection->maximumCount()); $this->assertEquals(false, $resultsReturned); }