Commit d4becf6b authored by František Bereň's avatar František Bereň Committed by lucasvanlierop

Update AbstractPostgreSqlPlatformTestCase.php

added postgresql platform conversion test
parent 1ae0bd89
......@@ -310,6 +310,23 @@ abstract class AbstractPostgreSqlPlatformTestCase extends AbstractPlatformTestCa
$this->assertEquals('1', $platform->convertBooleans(true));
$this->assertEquals('0', $platform->convertBooleans(false));
}
public function testConvertFromBoolean()
{
$platform = $this->createPlatform();
$this->assertFalse($platform->convertFromBoolean(false));
$this->assertFalse($platform->convertFromBoolean('false'));
$this->assertFalse($platform->convertFromBoolean('f'));
$this->assertFalse($platform->convertFromBoolean('no'));
$this->assertFalse($platform->convertFromBoolean('n'));
$this->assertFalse($platform->convertFromBoolean('0'));
$this->assertTrue($platform->convertFromBoolean(true));
$this->assertTrue($platform->convertFromBoolean('true'));
$this->assertTrue($platform->convertFromBoolean('t'));
$this->assertTrue($platform->convertFromBoolean('yes'));
$this->assertTrue($platform->convertFromBoolean('y'));
$this->assertTrue($platform->convertFromBoolean('1'));
}
public function testGetCreateSchemaSQL()
{
......
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