1
0
mirror of synced 2025-01-30 12:01:44 +03:00

fix tests

This commit is contained in:
Fabio B. Silva 2012-04-01 15:09:23 -03:00
parent 67f0722211
commit e9974911fe
2 changed files with 25 additions and 25 deletions

View File

@ -153,7 +153,7 @@ class EntityGenerator
Type::SMALLINT => 'integer', Type::SMALLINT => 'integer',
Type::TEXT => 'string', Type::TEXT => 'string',
Type::BLOB => 'string', Type::BLOB => 'string',
Type::DECIMAL => 'double', Type::DECIMAL => 'float',
); );
/** /**

View File

@ -311,65 +311,65 @@ class EntityGeneratorTest extends \Doctrine\Tests\OrmTestCase
*/ */
public function getEntityTypeAliasDataProvider() public function getEntityTypeAliasDataProvider()
{ {
return array(array( return array(
array( array(array(
'fieldName' => 'datetimetz', 'fieldName' => 'datetimetz',
'phpType' => '\\DateTime', 'phpType' => '\\DateTime',
'dbType' => 'datetimetz', 'dbType' => 'datetimetz',
'value' => new \DateTime 'value' => new \DateTime
), )),
array( array(array(
'fieldName' => 'datetime', 'fieldName' => 'datetime',
'phpType' => '\\DateTime', 'phpType' => '\\DateTime',
'dbType' => 'datetime', 'dbType' => 'datetime',
'value' => new \DateTime 'value' => new \DateTime
), )),
array( array(array(
'fieldName' => 'date', 'fieldName' => 'date',
'phpType' => '\\DateTime', 'phpType' => '\\DateTime',
'dbType' => 'date', 'dbType' => 'date',
'value' => new \DateTime 'value' => new \DateTime
), )),
array( array(array(
'fieldName' => 'time', 'fieldName' => 'time',
'phpType' => '\DateTime', 'phpType' => '\DateTime',
'dbType' => 'time', 'dbType' => 'time',
'value' => new \DateTime 'value' => new \DateTime
), )),
array( array(array(
'fieldName' => 'object', 'fieldName' => 'object',
'phpType' => '\stdClass', 'phpType' => '\stdClass',
'dbType' => 'object', 'dbType' => 'object',
'value' => new \stdClass() 'value' => new \stdClass()
), )),
array( array(array(
'fieldName' => 'bigint', 'fieldName' => 'bigint',
'phpType' => 'integer', 'phpType' => 'integer',
'dbType' => 'bigint', 'dbType' => 'bigint',
'value' => 11 'value' => 11
), )),
array( array(array(
'fieldName' => 'smallint', 'fieldName' => 'smallint',
'phpType' => 'integer', 'phpType' => 'integer',
'type' => 'smallint', 'dbType' => 'smallint',
'value' => 22 'value' => 22
), )),
array( array(array(
'fieldName' => 'text', 'fieldName' => 'text',
'phpType' => 'string', 'phpType' => 'string',
'dbType' => 'text', 'dbType' => 'text',
'value' => 'text' 'value' => 'text'
), )),
array( array(array(
'fieldName' => 'blob', 'fieldName' => 'blob',
'phpType' => 'string', 'phpType' => 'string',
'dbType' => 'blob', 'dbType' => 'blob',
'value' => 'blob' 'value' => 'blob'
), )),
array( array(array(
'fieldName' => 'blob', 'fieldName' => 'decimal',
'phpType' => 'double', 'phpType' => 'float',
'dbType' => 'blob', 'dbType' => 'decimal',
'value' => 33.33 'value' => 33.33
), ),
)); ));