Permalink
Browse files

Test to prove ticket #253

  • Loading branch information...
1 parent 30dc0cf commit dd0c4a64c5ec65940a6a60fea771d65ea77289e8 @ceeram ceeram committed with markstory Nov 4, 2009
Showing with 11 additions and 0 deletions.
  1. +11 −0 cake/tests/cases/libs/model/behaviors/containable.test.php
@@ -3384,6 +3384,17 @@ function testResetDeeperHasOneAssociations() {
$expected = $this->Article->User->hasOne;
$this->Article->find('all', array(
'contain' => array(
+ 'User' => array(
+ 'Comment' => array('fields' => array('created'))
+ )
+ )
+ ));
+ $this->assertEqual($expected, $this->Article->User->hasOne);
+
+ $this->Article->User->bindModel($userHasOne, false);
+ $expected = $this->Article->User->hasOne;
+ $this->Article->find('all', array(
+ 'contain' => array(
'User.ArticleFeatured' => array(
'conditions' => array('ArticleFeatured.published' => 'Y')
),

0 comments on commit dd0c4a6

Please sign in to comment.