Source of file TextPageTest.php
Size: 0,724 Bytes - Last Modified: 2021-12-24T06:45:31+00:00
/var/www/docs.ssmods.com/process/src/tests/TextPageTest.php
123456789101112131415161718192021222324252627 | <?php /** * Class TextPageTest * Run tests to check the Text Page and it's functionality * * @method void assertEquals(mixed $param1, mixed $param2) */ class TextPageTest extends SapphireTest { public static $fixture_file = 'fixtures/TextPageTest.yml'; /** * Test that the page is saved in the DB and it's response does not include any html markup */ public function testCreation(){ $this->objFromFixture('TextPage', 'test'); $controller = TextPage_Controller::create(TextPage::get()->first()); $render = trim($controller->render()->value); $this->assertEquals( $render, 'Some text' ); $this->assertEquals( strip_tags($render), $render ); } } |