[libdbd-pg-perl] 01/35: Reset pg_enable_utf8 after setting client_encoding in tests
Christoph Berg
myon at debian.org
Wed Sep 27 17:41:02 UTC 2017
This is an automated email from the git hooks/post-receive script.
myon pushed a commit to branch master
in repository libdbd-pg-perl.
commit 45e764b2d142fe151d51f00f1bd6e0278202ce45
Author: Dagfinn Ilmari Mannsåker <ilmari at ilmari.org>
Date: Thu Jul 6 16:52:47 2017 +0100
Reset pg_enable_utf8 after setting client_encoding in tests
This fixes running the tests against an SQL_ASCII database
(Github issue #26)
Commit 1dcdca74 moved the client_encoding setting from the connect
string to a SET command, but DBD::Pg does't detect that automatically,
so didn't en-/de-code data to/from UTF-8.
---
Changes | 2 ++
t/dbdpg_test_setup.pl | 1 +
2 files changed, 3 insertions(+)
diff --git a/Changes b/Changes
index 7585052..ab0ea60 100644
--- a/Changes
+++ b/Changes
@@ -1,4 +1,6 @@
+ - Fix running tests with non-UTF8 server_encoding
+ (Github issue #26)
Version 3.6.2 Released May 23, 2017 (git tag 3.6.2)
diff --git a/t/dbdpg_test_setup.pl b/t/dbdpg_test_setup.pl
index 9c01ae7..8eaab40 100644
--- a/t/dbdpg_test_setup.pl
+++ b/t/dbdpg_test_setup.pl
@@ -660,6 +660,7 @@ version: $version
if (!$arg->{quickreturn} or 1 != $arg->{quickreturn}) {
## non-ASCII parts of the tests assume UTF8
$dbh->do('SET client_encoding = utf8');
+ $dbh->{pg_enable_utf8} = -1;
}
if ($arg->{quickreturn}) {
--
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/pkg-perl/packages/libdbd-pg-perl.git
More information about the Pkg-perl-cvs-commits
mailing list