From 584c55faacf7cc408ee4f459241e1282780e6bd0 Mon Sep 17 00:00:00 2001 From: zYne Date: Fri, 16 Feb 2007 19:33:32 +0000 Subject: [PATCH] --- tests/DataDict/FirebirdTestCase.php | 77 +++++++++++++++++++++++------ 1 file changed, 61 insertions(+), 16 deletions(-) diff --git a/tests/DataDict/FirebirdTestCase.php b/tests/DataDict/FirebirdTestCase.php index a6073a258..a1d172b49 100644 --- a/tests/DataDict/FirebirdTestCase.php +++ b/tests/DataDict/FirebirdTestCase.php @@ -53,90 +53,135 @@ class Doctrine_DataDict_Firebird_TestCase extends Doctrine_UnitTestCase { $type = $this->dataDict->getPortableDeclaration(array('type' => 'date')); - $this->assertEqual($type, array(array('date'), null, null, null)); + $this->assertEqual($type, array('type' => array('date'), + 'length' => null, + 'unsigned' => null, + 'fixed' => null)); } public function testGetPortableDeclarationSupportsNativeTimestampType() { $type = $this->dataDict->getPortableDeclaration(array('type' => 'timestamp')); - $this->assertEqual($type, array(array('timestamp'), null, null, null)); + $this->assertEqual($type, array('type' => array('timestamp'), + 'length' => null, + 'unsigned' => null, + 'fixed' => null)); } public function testGetPortableDeclarationSupportsNativeTimeType() { $type = $this->dataDict->getPortableDeclaration(array('type' => 'time')); - $this->assertEqual($type, array(array('time'), null, null, null)); + $this->assertEqual($type, array('type' => array('time'), + 'length' => null, + 'unsigned' => null, + 'fixed' => null)); } public function testGetPortableDeclarationSupportsNativeFloatType() { $type = $this->dataDict->getPortableDeclaration(array('type' => 'float')); - $this->assertEqual($type, array(array('float'), null, null, null)); + $this->assertEqual($type, array('type' => array('float'), + 'length' => null, + 'unsigned' => null, + 'fixed' => null)); } public function testGetPortableDeclarationSupportsNativeDoubleType() { $type = $this->dataDict->getPortableDeclaration(array('type' => 'double')); - $this->assertEqual($type, array(array('float'), null, null, null)); + $this->assertEqual($type, array('type' => array('float'), + 'length' => null, + 'unsigned' => null, + 'fixed' => null)); } public function testGetPortableDeclarationSupportsNativeDoublePrecisionType() { $type = $this->dataDict->getPortableDeclaration(array('type' => 'double precision')); - $this->assertEqual($type, array(array('float'), null, null, null)); + $this->assertEqual($type, array('type' => array('float'), + 'length' => null, + 'unsigned' => null, + 'fixed' => null)); } public function testGetPortableDeclarationSupportsNativeDfloatType() { $type = $this->dataDict->getPortableDeclaration(array('type' => 'd_float')); - $this->assertEqual($type, array(array('float'), null, null, null)); + $this->assertEqual($type, array('type' => array('float'), + 'length' => null, + 'unsigned' => null, + 'fixed' => null)); } public function testGetPortableDeclarationSupportsNativeDecimalType() { $type = $this->dataDict->getPortableDeclaration(array('type' => 'decimal')); - $this->assertEqual($type, array(array('decimal'), null, null, null)); + $this->assertEqual($type, array('type' => array('decimal'), + 'length' => null, + 'unsigned' => null, + 'fixed' => null)); } public function testGetPortableDeclarationSupportsNativeNumericType() { $type = $this->dataDict->getPortableDeclaration(array('type' => 'numeric')); - $this->assertEqual($type, array(array('decimal'), null, null, null)); + $this->assertEqual($type, array('type' => array('decimal'), + 'length' => null, + 'unsigned' => null, + 'fixed' => null)); } public function testGetPortableDeclarationSupportsNativeBlobType() { $type = $this->dataDict->getPortableDeclaration(array('type' => 'blob')); - $this->assertEqual($type, array(array('blob'), null, null, null)); + $this->assertEqual($type, array('type' => array('blob'), + 'length' => null, + 'unsigned' => null, + 'fixed' => null)); } public function testGetPortableDeclarationSupportsNativeVarcharType() { $type = $this->dataDict->getPortableDeclaration(array('type' => 'varchar')); - $this->assertEqual($type, array(array('string'), null, null, false)); + $this->assertEqual($type, array('type' => array('string'), + 'length' => null, + 'unsigned' => null, + 'fixed' => null)); } public function testGetPortableDeclarationSupportsNativeCharType() { $type = $this->dataDict->getPortableDeclaration(array('type' => 'char')); - $this->assertEqual($type, array(array('string'), null, null, true)); + $this->assertEqual($type, array('type' => array('string'), + 'length' => null, + 'unsigned' => null, + 'fixed' => true)); } public function testGetPortableDeclarationSupportsNativeCstringType() { $type = $this->dataDict->getPortableDeclaration(array('type' => 'cstring')); - $this->assertEqual($type, array(array('string'), null, null, true)); + $this->assertEqual($type, array('type' => array('string'), + 'length' => null, + 'unsigned' => null, + 'fixed' => true)); } - public function testGetPortableDeclarationSupportsNativeBigintType() + public function testGetPortableDeclarationSupportsNativeBigintType() { $type = $this->dataDict->getPortableDeclaration(array('type' => 'bigint')); - $this->assertEqual($type, array(array('integer'), null, null, null)); + $this->assertEqual($type, array('type' => array('integer'), + 'length' => null, + 'unsigned' => null, + 'fixed' => null)); } public function testGetPortableDeclarationSupportsNativeQuadType() { $type = $this->dataDict->getPortableDeclaration(array('type' => 'quad')); - $this->assertEqual($type, array(array('integer'), null, null, null)); + $this->assertEqual($type, array('type' => array('integer'), + 'length' => null, + 'unsigned' => null, + 'fixed' => null)); } public function testGetNativeDefinitionSupportsIntegerType() {