Ojs\AdminBundle\Tests\Controller\AdminPeriodControllerTest::testEdit PHP Метод

testEdit() публичный Метод

public testEdit ( )
    public function testEdit()
    {
        $this->logIn();
        $client = $this->client;
        $crawler = $client->request('GET', '/admin/period/1/edit');
        $this->assertStatusCode(200, $client);
        $form = $crawler->filter('form[name=period]')->form();
        $form['period[translations][' . $this->locale . '][period]'] = 'Period Edit - phpunit';
        $crawler = $client->submit($form);
        $this->assertTrue($client->getResponse()->isRedirect());
        $client->followRedirect();
        $this->assertContains('Period Edit - phpunit', $this->client->getResponse()->getContent());
    }