1 |
idella4 14/07/30 02:08:48 |
2 |
|
3 |
Added: 0.9.7-test-fix.patch |
4 |
Log: |
5 |
upgrade test deps, test phase |
6 |
|
7 |
(Portage version: 2.2.10/cvs/Linux x86_64, signed Manifest commit with key 0xB8072B0D) |
8 |
|
9 |
Revision Changes Path |
10 |
1.1 dev-python/sqlalchemy/files/0.9.7-test-fix.patch |
11 |
|
12 |
file : http://sources.gentoo.org/viewvc.cgi/gentoo-x86/dev-python/sqlalchemy/files/0.9.7-test-fix.patch?rev=1.1&view=markup |
13 |
plain: http://sources.gentoo.org/viewvc.cgi/gentoo-x86/dev-python/sqlalchemy/files/0.9.7-test-fix.patch?rev=1.1&content-type=text/plain |
14 |
|
15 |
Index: 0.9.7-test-fix.patch |
16 |
=================================================================== |
17 |
From 405c223ae50e78dacac08783c414619db20df0b7 Mon Sep 17 00:00:00 2001 |
18 |
From: Mike Bayer <mike_mp@××××××××××××.com> |
19 |
Date: Tue, 29 Jul 2014 13:32:05 -0400 |
20 |
Subject: [PATCH] - Fixed 0.9.7 regression caused by :ticket:`3067` in |
21 |
conjunction with a mis-named unit test such that so-called "schema" types |
22 |
like :class:`.Boolean` and :class:`.Enum` could no longer be pickled. fixes |
23 |
#3144 |
24 |
|
25 |
diff --git a/lib/sqlalchemy/sql/elements.py b/lib/sqlalchemy/sql/elements.py |
26 |
index 6114460..6cbf583 100644 |
27 |
--- a/lib/sqlalchemy/sql/elements.py |
28 |
+++ b/lib/sqlalchemy/sql/elements.py |
29 |
@@ -3276,6 +3276,9 @@ class _defer_name(_truncated_label): |
30 |
else: |
31 |
return super(_defer_name, cls).__new__(cls, value) |
32 |
|
33 |
+ def __reduce__(self): |
34 |
+ return self.__class__, (util.text_type(self), ) |
35 |
+ |
36 |
|
37 |
class _defer_none_name(_defer_name): |
38 |
"""indicate a 'deferred' name that was ultimately the value None.""" |
39 |
diff --git a/test/sql/test_types.py b/test/sql/test_types.py |
40 |
index 03d3997..efa0f90 100644 |
41 |
--- a/test/sql/test_types.py |
42 |
+++ b/test/sql/test_types.py |
43 |
@@ -234,9 +234,9 @@ class TypeAffinityTest(fixtures.TestBase): |
44 |
assert t1.dialect_impl(d)._type_affinity is postgresql.UUID |
45 |
|
46 |
|
47 |
-class PickleMetadataTest(fixtures.TestBase): |
48 |
+class PickleTypesTest(fixtures.TestBase): |
49 |
|
50 |
- def testmeta(self): |
51 |
+ def test_pickle_types(self): |
52 |
for loads, dumps in picklers(): |
53 |
column_types = [ |
54 |
Column('Boo', Boolean()), |