This is an automated email from the git hooks/post-receive script. It was
generated because a ref change was pushed to the repository containing
the project "SQLObject development repository".
The branch, master has been updated
via 985b73167935bdd1c59f461079c6bb1642122d40 (commit)
via a05eb21b45515709f824f63a2f3db0d4286cb315 (commit)
via 510e58c1313eb0fc660183bdf0256b8063959fa0 (commit)
from 4ac1463aedf9e4fdb7a898d4b02c2f199148b70a (commit)
Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.
- Log -----------------------------------------------------------------
http://sourceforge.net/p/sqlobject/sqlobject/ci/985b73167935bdd1c59f461079c6bb1642122d40
commit 985b73167935bdd1c59f461079c6bb1642122d40
Merge: 4ac1463 a05eb21
Author: Oleg Broytman <ph...@ph...>
Date: Thu Mar 5 02:28:36 2015 +0300
Merge pull request #107 from drnlm/fix_test_unicode
Fix test unicode
http://sourceforge.net/p/sqlobject/sqlobject/ci/a05eb21b45515709f824f63a2f3db0d4286cb315
commit a05eb21b45515709f824f63a2f3db0d4286cb315
Author: Neil <drn...@gm...>
Date: Wed Mar 4 18:06:30 2015 +0200
Skip dbEncoding test on python 3
diff --git a/sqlobject/tests/test_unicode.py b/sqlobject/tests/test_unicode.py
index 76ffada..768e0a1 100644
--- a/sqlobject/tests/test_unicode.py
+++ b/sqlobject/tests/test_unicode.py
@@ -1,4 +1,5 @@
import sys
+import py.test
from sqlobject import *
from sqlobject.tests.dbtest import *
@@ -100,6 +101,9 @@ def test_select():
def test_dbEncoding():
+ if sys.version_info[0] > 2:
+ # Python 3 mostly ignores dbEncoding
+ py.test.skip("This test is for python 2")
setup()
TestUnicode.sqlmeta.dbEncoding = 'utf-8'
_test_select()
http://sourceforge.net/p/sqlobject/sqlobject/ci/510e58c1313eb0fc660183bdf0256b8063959fa0
commit 510e58c1313eb0fc660183bdf0256b8063959fa0
Author: Neil <drn...@gm...>
Date: Wed Mar 4 18:06:13 2015 +0200
Compare against actual strings on python 3
diff --git a/sqlobject/tests/test_unicode.py b/sqlobject/tests/test_unicode.py
index 8ad5468..76ffada 100644
--- a/sqlobject/tests/test_unicode.py
+++ b/sqlobject/tests/test_unicode.py
@@ -1,3 +1,5 @@
+import sys
+
from sqlobject import *
from sqlobject.tests.dbtest import *
@@ -39,9 +41,15 @@ def test_create():
FROM test_unicode
ORDER BY count
""")
- for count, col1, col2 in rows:
- assert data[count].encode('utf-8') == col1
- assert data[count].encode('latin1') == col2
+ if sys.version_info[0] == 2:
+ for count, col1, col2 in rows:
+ assert data[count].encode('utf-8') == col1
+ assert data[count].encode('latin1') == col2
+ else:
+ # On python 3, everthings already decoded to unicode
+ for count, col1, col2 in rows:
+ assert data[count] == col1
+ assert data[count] == col2
def _test_select():
-----------------------------------------------------------------------
Summary of changes:
sqlobject/tests/test_unicode.py | 18 +++++++++++++++---
1 files changed, 15 insertions(+), 3 deletions(-)
hooks/post-receive
--
SQLObject development repository
|