Skip to content

Commit

Permalink
added tests
Browse files Browse the repository at this point in the history
  • Loading branch information
AlexAlexandru committed Jul 19, 2018
1 parent 1aa0108 commit a58eb70
Showing 1 changed file with 10 additions and 0 deletions.
10 changes: 10 additions & 0 deletions lib/Cake/Test/Case/Model/Behavior/TranslateBehaviorTest.php
Expand Up @@ -1144,6 +1144,16 @@ public function testFieldsRestoreAfterBind() {
$TestModel->bindTranslation($translations);

$result = $TestModel->find('first');
$TestModel->find('first', array(
'fields' => array(
'TranslatedItem.title',
),
));
$TestModel->find('first', array(
'fields' => array(
'TranslatedItem.title',
),
));
$this->assertArrayHasKey('Title', $result);
$this->assertArrayHasKey('content', $result['Title'][0]);
$this->assertArrayNotHasKey('title', $result);
Expand Down

0 comments on commit a58eb70

Please sign in to comment.