Remove duplicated test case

We prefer to test across all platforms at once with
`SchemaManagerFunctionalTestCase::testEscapedDefaultValueMustBePreserved()`
rather than to test only a single specific platform.
parent 44637bfa
...@@ -444,27 +444,13 @@ class MySqlSchemaManagerTest extends SchemaManagerFunctionalTestCase ...@@ -444,27 +444,13 @@ class MySqlSchemaManagerTest extends SchemaManagerFunctionalTestCase
} }
/** /**
* Ensure default values (un-)escaping is properly done by mysql platforms. * Returns literals that are platform specific escaped.
* The test is voluntarily relying on schema introspection due to current *
* doctrine limitations. Once #2850 is landed, this test can be removed.
* @see https://dev.mysql.com/doc/refman/5.7/en/string-literals.html * @see https://dev.mysql.com/doc/refman/5.7/en/string-literals.html
*
* @return array
*/ */
public function testEnsureDefaultsAreUnescapedFromSchemaIntrospection() : void protected function getEscapedLiterals(): array
{
$platform = $this->_sm->getDatabasePlatform();
$this->_conn->query('DROP TABLE IF EXISTS test_column_defaults_with_create');
$default = implode('+', $this->getEscapedLiterals());
$sql = "CREATE TABLE test_column_defaults_with_create(
col1 VARCHAR(255) NULL DEFAULT {$platform->quoteStringLiteral($default)}
)";
$this->_conn->query($sql);
$onlineTable = $this->_sm->listTableDetails("test_column_defaults_with_create");
self::assertSame($default, $onlineTable->getColumn('col1')->getDefault());
}
protected function getEscapedLiterals() : array
{ {
return [ return [
"\\0", // An ASCII NUL (X'00') character "\\0", // An ASCII NUL (X'00') character
......
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