From 757579e1d190b60db15db0ebe659661432f74182 Mon Sep 17 00:00:00 2001 From: Norio Suzuki Date: Fri, 24 Feb 2012 19:05:08 +0900 Subject: [PATCH] Fixed a testcase, support PostgreSQL 9.1 Signed-off-by: mark_story --- .../Model/Datasource/Database/PostgresTest.php | 16 ++++++++-------- 1 file changed, 8 insertions(+), 8 deletions(-) diff --git a/lib/Cake/Test/Case/Model/Datasource/Database/PostgresTest.php b/lib/Cake/Test/Case/Model/Datasource/Database/PostgresTest.php index f1b400763..b416870bd 100644 --- a/lib/Cake/Test/Case/Model/Datasource/Database/PostgresTest.php +++ b/lib/Cake/Test/Case/Model/Datasource/Database/PostgresTest.php @@ -852,23 +852,23 @@ class PostgresTest extends CakeTestCase { $this->assertEquals(2, substr_count($result, 'field_two'), 'Too many fields'); $this->assertFalse(strpos(';ALTER', $result), 'Too many semi colons'); } - + /** * test encoding setting. * * @return void */ public function testEncoding() { - $result = $this->Dbo->setEncoding('utf8'); + $result = $this->Dbo->setEncoding('UTF8'); $this->assertTrue($result) ; - + $result = $this->Dbo->getEncoding(); - $this->assertEquals('utf8', $result) ; - - $result = $this->Dbo->setEncoding('EUC-JP'); + $this->assertEquals('UTF8', $result) ; + + $result = $this->Dbo->setEncoding('EUC_JP'); /* 'EUC_JP' is right character code name in PostgreSQL */ $this->assertTrue($result) ; - + $result = $this->Dbo->getEncoding(); - $this->assertEquals('EUC-JP', $result) ; + $this->assertEquals('EUC_JP', $result) ; } }