Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

Added decimal CakeSchema test case and DatatypeFixture. #3171

  • Loading branch information...
commit e0eb8f8e18da7f23f85119b78eae735230115a89 1 parent a1a3e70
U-Zyn Chua uzyn authored
1  lib/Cake/Test/Case/Model/CakeSchemaTest.php
View
@@ -174,6 +174,7 @@ class TestAppSchema extends CakeSchema {
public $datatypes = array(
'id' => array('type' => 'integer', 'null' => false, 'default' => 0, 'key' => 'primary'),
'float_field' => array('type' => 'float', 'null' => false, 'length' => '5,2', 'default' => ''),
+ 'decimal_field' => array('type' => 'decimal', 'length' => '6,3', 'default' => '0.000'),
'huge_int' => array('type' => 'biginteger'),
'bool' => array('type' => 'boolean', 'null' => false, 'default' => false),
'indexes' => array('PRIMARY' => array('column' => 'id', 'unique' => true)),
1  lib/Cake/Test/Fixture/DatatypeFixture.php
View
@@ -33,6 +33,7 @@ class DatatypeFixture extends CakeTestFixture {
public $fields = array(
'id' => array('type' => 'integer', 'null' => false, 'default' => 0, 'key' => 'primary'),
'float_field' => array('type' => 'float', 'length' => '5,2', 'null' => false, 'default' => null),
+ 'decimal_field' => array('type' => 'decimal', 'length' => '6,3', 'default' => '0.000'),
'huge_int' => array('type' => 'biginteger'),
'bool' => array('type' => 'boolean', 'null' => false, 'default' => false),
);
Please sign in to comment.
Something went wrong with that request. Please try again.