From e9974911fef2bb478dec81747437d3a67f7e1319 Mon Sep 17 00:00:00 2001 From: "Fabio B. Silva" Date: Sun, 1 Apr 2012 15:09:23 -0300 Subject: [PATCH] fix tests --- lib/Doctrine/ORM/Tools/EntityGenerator.php | 2 +- .../Tests/ORM/Tools/EntityGeneratorTest.php | 48 +++++++++---------- 2 files changed, 25 insertions(+), 25 deletions(-) diff --git a/lib/Doctrine/ORM/Tools/EntityGenerator.php b/lib/Doctrine/ORM/Tools/EntityGenerator.php index 4d490aa30..28bb1bca0 100644 --- a/lib/Doctrine/ORM/Tools/EntityGenerator.php +++ b/lib/Doctrine/ORM/Tools/EntityGenerator.php @@ -153,7 +153,7 @@ class EntityGenerator Type::SMALLINT => 'integer', Type::TEXT => 'string', Type::BLOB => 'string', - Type::DECIMAL => 'double', + Type::DECIMAL => 'float', ); /** diff --git a/tests/Doctrine/Tests/ORM/Tools/EntityGeneratorTest.php b/tests/Doctrine/Tests/ORM/Tools/EntityGeneratorTest.php index 8ebed3433..d614b96a1 100644 --- a/tests/Doctrine/Tests/ORM/Tools/EntityGeneratorTest.php +++ b/tests/Doctrine/Tests/ORM/Tools/EntityGeneratorTest.php @@ -311,65 +311,65 @@ class EntityGeneratorTest extends \Doctrine\Tests\OrmTestCase */ public function getEntityTypeAliasDataProvider() { - return array(array( - array( + return array( + array(array( 'fieldName' => 'datetimetz', 'phpType' => '\\DateTime', 'dbType' => 'datetimetz', 'value' => new \DateTime - ), - array( + )), + array(array( 'fieldName' => 'datetime', 'phpType' => '\\DateTime', 'dbType' => 'datetime', 'value' => new \DateTime - ), - array( + )), + array(array( 'fieldName' => 'date', 'phpType' => '\\DateTime', 'dbType' => 'date', 'value' => new \DateTime - ), - array( + )), + array(array( 'fieldName' => 'time', 'phpType' => '\DateTime', 'dbType' => 'time', 'value' => new \DateTime - ), - array( + )), + array(array( 'fieldName' => 'object', 'phpType' => '\stdClass', 'dbType' => 'object', 'value' => new \stdClass() - ), - array( + )), + array(array( 'fieldName' => 'bigint', 'phpType' => 'integer', 'dbType' => 'bigint', 'value' => 11 - ), - array( + )), + array(array( 'fieldName' => 'smallint', 'phpType' => 'integer', - 'type' => 'smallint', + 'dbType' => 'smallint', 'value' => 22 - ), - array( + )), + array(array( 'fieldName' => 'text', 'phpType' => 'string', 'dbType' => 'text', 'value' => 'text' - ), - array( + )), + array(array( 'fieldName' => 'blob', 'phpType' => 'string', 'dbType' => 'blob', 'value' => 'blob' - ), - array( - 'fieldName' => 'blob', - 'phpType' => 'double', - 'dbType' => 'blob', + )), + array(array( + 'fieldName' => 'decimal', + 'phpType' => 'float', + 'dbType' => 'decimal', 'value' => 33.33 ), ));