Commit 68e9c5f3 authored by Shane Archer's avatar Shane Archer Committed by Marco Pivetta

Splitting second test into its own test method.

parent d8709c5c
......@@ -441,6 +441,17 @@ abstract class AbstractPlatformTestCase extends \Doctrine\Tests\DbalTestCase
}
public function testGetDefaultValueDeclarationSQL()
{
// non-timestamp value will get single quotes
$field = array(
'type' => 'string',
'default' => 'non_timestamp'
);
$this->assertEquals(" DEFAULT 'non_timestamp'", $this->_platform->getDefaultValueDeclarationSQL($field));
}
public function testGetDefaultValueDeclarationSQLDateTime()
{
// timestamps on datetime types should not be quoted
foreach (array('datetime', 'datetimetz') as $type) {
......@@ -453,14 +464,6 @@ abstract class AbstractPlatformTestCase extends \Doctrine\Tests\DbalTestCase
$this->assertEquals(' DEFAULT ' . $this->_platform->getCurrentTimestampSQL(), $this->_platform->getDefaultValueDeclarationSQL($field));
}
// non-timestamp value will get single quotes
$field = array(
'type' => 'string',
'default' => 'non_timestamp'
);
$this->assertEquals(" DEFAULT 'non_timestamp'", $this->_platform->getDefaultValueDeclarationSQL($field));
}
/**
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment