Skip to content

Commit

Permalink
It's only necessary to override abstract methods
Browse files Browse the repository at this point in the history
So, don't just copy and paste the setup method call
  • Loading branch information
AD7six committed Feb 10, 2015
1 parent 95fe4ce commit 5a3a48b
Showing 1 changed file with 3 additions and 8 deletions.
11 changes: 3 additions & 8 deletions tests/TestCase/ORM/AssociationTest.php
Expand Up @@ -187,12 +187,10 @@ public function testTargetPlugin()
'sourceTable' => $this->source,
'joinType' => 'INNER'
];

$this->association = $this->getMock(
'\Cake\ORM\Association',
[
'_options', 'attachTo', '_joinCondition', 'cascadeDelete', 'isOwningSide',
'saveAssociated', 'eagerLoader', 'type'
],
['type', 'eagerLoader', 'cascadeDelete', 'isOwningSide', 'saveAssociated'],
['ThisAssociationName', $config]
);

Expand Down Expand Up @@ -302,10 +300,7 @@ public function testFinderInConstructor()
];
$assoc = $this->getMock(
'\Cake\ORM\Association',
[
'_options', 'attachTo', '_joinCondition', 'cascadeDelete', 'isOwningSide',
'saveAssociated', 'eagerLoader', 'type'
],
['type', 'eagerLoader', 'cascadeDelete', 'isOwningSide', 'saveAssociated'],
['Foo', $config]
);
$this->assertEquals('published', $assoc->finder());
Expand Down

0 comments on commit 5a3a48b

Please sign in to comment.