1
0
mirror of synced 2025-01-31 04:21:44 +03:00

#1252 DDC-3496 - moving stub naming strategy to tests directory

This commit is contained in:
Marco Pivetta 2015-01-18 00:07:54 +01:00
parent 29007e7d79
commit 369a9934a5
2 changed files with 8 additions and 9 deletions

View File

@ -18,15 +18,12 @@
* <http://www.doctrine-project.org>.
*/
namespace Doctrine\ORM\Mapping;
namespace Doctrine\Tests\ORM\Mapping\NamingStrategy;
use Doctrine\ORM\Mapping\DefaultNamingStrategy;
/**
* The default NamingStrategy
*
*
* @link www.doctrine-project.org
* @since 2.3
* @author Fabio B. Silva <fabio.bat.silva@gmail.com>
* Stub naming strategy to verify `joinColumnName` proper behavior
*/
class JoinColumnClassNamingStrategy extends DefaultNamingStrategy
{
@ -35,6 +32,8 @@ class JoinColumnClassNamingStrategy extends DefaultNamingStrategy
*/
public function joinColumnName($propertyName, $className = null)
{
return strtolower($this->classToTableName($className)) . '_' . $propertyName . '_' . $this->referenceColumnName();
return strtolower($this->classToTableName($className))
. '_' . $propertyName
. '_' . $this->referenceColumnName();
}
}

View File

@ -4,8 +4,8 @@ namespace Doctrine\Tests\ORM\Mapping;
use Doctrine\ORM\Mapping\UnderscoreNamingStrategy;
use Doctrine\ORM\Mapping\DefaultNamingStrategy;
use Doctrine\ORM\Mapping\JoinColumnClassNamingStrategy;
use Doctrine\ORM\Mapping\NamingStrategy;
use Doctrine\Tests\ORM\Mapping\NamingStrategy\JoinColumnClassNamingStrategy;
/**
* @group DDC-559