Minor dependency updates
[yaffs-website] / vendor / jcalderonzumba / mink-phantomjs-driver / tests / integration / Custom / PhantomJSStatusCodeTest.php
1 <?php
2
3 namespace Behat\Mink\Tests\Driver\Basic;
4
5 use Behat\Mink\Tests\Driver\TestCase;
6
7 class PhantomJSStatusCodeTest extends TestCase {
8   public function testStatuses() {
9     $this->getSession()->visit($this->pathTo('/index.html'));
10
11     $this->assertEquals(200, $this->getSession()->getStatusCode());
12     $this->assertEquals($this->pathTo('/index.html'), $this->getSession()->getCurrentUrl());
13
14     $this->getSession()->visit($this->pathTo('/404.php'));
15
16     $this->assertEquals($this->pathTo('/404.php'), $this->getSession()->getCurrentUrl());
17     $this->assertEquals(404, $this->getSession()->getStatusCode());
18     $this->assertEquals('Sorry, page not found', $this->getSession()->getPage()->getText());
19   }
20 }