You are here

public function HistoryTest::testClearIsEmpty in Zircon Profile 8

Same name and namespace in other branches
  1. 8.0 vendor/symfony/browser-kit/Tests/HistoryTest.php \Symfony\Component\BrowserKit\Tests\HistoryTest::testClearIsEmpty()

File

vendor/symfony/browser-kit/Tests/HistoryTest.php, line 37

Class

HistoryTest

Namespace

Symfony\Component\BrowserKit\Tests

Code

public function testClearIsEmpty() {
  $history = new History();
  $history
    ->add(new Request('http://www.example.com/', 'get'));
  $this
    ->assertFalse($history
    ->isEmpty(), '->isEmpty() returns false if the history is not empty');
  $history
    ->clear();
  $this
    ->assertTrue($history
    ->isEmpty(), '->isEmpty() true if the history is empty');
}