Skip to content

Commit b24e492

Browse files
committed
Unskip test.
Remove now invalid test code as those view properties are no longer set. The new ORM allows entities to carry validation messages with the records.
1 parent 3bba1eb commit b24e492

File tree

1 file changed

+1
-25
lines changed

1 file changed

+1
-25
lines changed

tests/TestCase/Controller/ControllerTest.php

Lines changed: 1 addition & 25 deletions
Original file line numberDiff line numberDiff line change
@@ -315,7 +315,6 @@ public function testConstructClassesWithComponents() {
315315
* @return void
316316
*/
317317
public function testRender() {
318-
$this->markTestIncomplete('Need to sort out a few more things with the ORM first.');
319318
Configure::write('App.namespace', 'TestApp');
320319
Plugin::load('TestPlugin');
321320

@@ -335,30 +334,7 @@ public function testRender() {
335334
$result = $Controller->render('/Element/test_element');
336335
$this->assertRegExp('/this is the test element/', (string)$result);
337336
$Controller->view = null;
338-
339-
$Controller = new TestController($request, new Response());
340-
$Controller->uses = ['TestPlugin.TestPluginComment'];
341-
$Controller->helpers = array('Html');
342-
$Controller->constructClasses();
343-
$expected = ['title' => 'tooShort'];
344-
$Controller->TestPluginComment->validationErrors = $expected;
345-
346-
$Controller->viewPath = 'Posts';
347-
$result = $Controller->render('index');
348-
$View = $Controller->View;
349-
$this->assertTrue(isset($View->validationErrors['TestPluginComment']));
350-
$this->assertEquals($expected, $View->validationErrors['TestPluginComment']);
351-
352-
$expectedModels = [
353-
'TestPluginComment' => [
354-
'className' => 'TestPlugin\Model\TestPluginComment'
355-
],
356-
'Post' => [
357-
'className' => 'TestApp\Model\Post'
358-
]
359-
];
360-
$this->assertEquals($expectedModels, $Controller->request->params['models']);
361-
}
337+
}
362338

363339
/**
364340
* test that a component beforeRender can change the controller view class.

0 commit comments

Comments
 (0)