Skip to content

Commit

Permalink
Updated TableLocatorTest.
Browse files Browse the repository at this point in the history
  • Loading branch information
robertpustulka committed Apr 9, 2015
1 parent 71e802d commit d52140f
Showing 1 changed file with 3 additions and 5 deletions.
8 changes: 3 additions & 5 deletions tests/TestCase/ORM/Locator/TableLocatorTest.php
Expand Up @@ -242,8 +242,8 @@ public function testGetExistingWithConfigData()
*/
public function testGetWithSameOption()
{
$result = $this->_locator->get('Users', ['className' => 'Cake\Test\TestCase\ORM\MyUsersTable']);
$result2 = $this->_locator->get('Users', ['className' => 'Cake\Test\TestCase\ORM\MyUsersTable']);
$result = $this->_locator->get('Users', ['className' => 'Cake\Test\TestCase\ORM\Locator\MyUsersTable']);
$result2 = $this->_locator->get('Users', ['className' => 'Cake\Test\TestCase\ORM\Locator\MyUsersTable']);
$this->assertEquals($result, $result2);
}

Expand Down Expand Up @@ -274,7 +274,7 @@ public function testGetWithConventions()
public function testGetPlugin()
{
Plugin::load('TestPlugin');
$table = $this->_locator->get('TestPlugin.TestPluginComments', ['connection' => 'test']);
$table = $this->_locator->get('TestPlugin.TestPluginComments');

$this->assertInstanceOf('TestPlugin\Model\Table\TestPluginCommentsTable', $table);
$this->assertFalse(
Expand Down Expand Up @@ -329,7 +329,6 @@ public function testGetPluginWithClassNameOption()
Plugin::load('TestPlugin');
$table = $this->_locator->get('Comments', [
'className' => 'TestPlugin.TestPluginComments',
'connection' => 'test'
]);
$class = 'TestPlugin\Model\Table\TestPluginCommentsTable';
$this->assertInstanceOf($class, $table);
Expand All @@ -352,7 +351,6 @@ public function testGetPluginWithFullNamespaceName()
$class = 'TestPlugin\Model\Table\TestPluginCommentsTable';
$table = $this->_locator->get('Comments', [
'className' => $class,
'connection' => 'test'
]);
$this->assertInstanceOf($class, $table);
$this->assertFalse($this->_locator->exists('TestPluginComments'), 'Class name should not exist');
Expand Down

0 comments on commit d52140f

Please sign in to comment.