Adding test case for find(list) with recursive.

This commit is contained in:
mark_story 2010-07-11 18:38:27 -04:00
parent 6d8724097e
commit e382a1c63c

View file

@ -6408,6 +6408,18 @@ class ModelReadTest extends BaseModelTest {
4 => 'garrett (CakePHP)'
);
$this->assertEqual($result, $expected);
$TestModel =& new Article();
$TestModel->displayField = 'title';
$result = $TestModel->find('list', array(
'conditions' => array('User.user' => 'mariano'),
'recursive' => 0
));
$expected = array(
1 => 'First Article',
3 => 'Third Article'
);
$this->assertEqual($result, $expected);
}
/**