1 | <?php |
||
13 | class PartialUserFormControllerFunctionalTest extends FunctionalTest |
||
14 | { |
||
15 | /** |
||
16 | * @var string |
||
17 | */ |
||
18 | protected static $fixture_file = '../fixtures/partialformtest.yml'; |
||
19 | |||
20 | public function setUp() |
||
26 | |||
27 | public function testPartialPage() |
||
32 | |||
33 | public function xtestPartialValidKeyToken() |
||
34 | { |
||
35 | $token = 'q1w2e3r4t5y6u7i8'; |
||
36 | // No Parent |
||
37 | $key = singleton(PartialFormSubmission::class)->generateKey($token); |
||
38 | $result = $this->get("partial/{$key}/{$token}"); |
||
39 | $this->assertEquals(404, $result->getStatusCode()); |
||
40 | |||
41 | // Partial with UserDefinedForm |
||
42 | $key = $this->objFromFixture(PartialFormSubmission::class, 'submission1')->generateKey($token); |
||
43 | $result = $this->get("partial/{$key}/{$token}"); |
||
44 | $this->assertEquals(200, $result->getStatusCode()); |
||
45 | $this->assertContains('Field 1', $result->getBody()); |
||
46 | } |
||
47 | |||
48 | public function testPartialInvalidToken() |
||
56 | |||
57 | public function testPartialInvalidKey() |
||
71 | } |
||
72 |