~ubuntu-branches/debian/jessie/sqlalchemy/jessie

« back to all changes in this revision

Viewing changes to test/orm/inheritance/test_assorted_poly.py

  • Committer: Package Import Robot
  • Author(s): Piotr Ożarowski, Jakub Wilk, Piotr Ożarowski
  • Date: 2013-07-06 20:53:52 UTC
  • mfrom: (1.4.23) (16.1.17 experimental)
  • Revision ID: package-import@ubuntu.com-20130706205352-ryppl1eto3illd79
Tags: 0.8.2-1
[ Jakub Wilk ]
* Use canonical URIs for Vcs-* fields.

[ Piotr Ożarowski ]
* New upstream release
* Upload to unstable
* Build depend on python3-all instead of -dev, extensions are not built for
  Python 3.X 

Show diffs side-by-side

added added

removed removed

Lines of Context:
3
3
 
4
4
"""
5
5
 
6
 
from test.lib.testing import eq_
 
6
from sqlalchemy.testing import eq_
7
7
from sqlalchemy import *
8
8
from sqlalchemy import util
9
9
from sqlalchemy.orm import *
10
10
from sqlalchemy.orm.interfaces import MANYTOONE
11
 
from test.lib import AssertsExecutionResults, testing
12
 
from test.lib.util import function_named
13
 
from test.lib import fixtures
 
11
from sqlalchemy.testing import AssertsExecutionResults
 
12
from sqlalchemy import testing
 
13
from sqlalchemy.testing.util import function_named
 
14
from sqlalchemy.testing import fixtures
14
15
from test.orm import _fixtures
15
 
from test.lib.testing import eq_
16
 
from test.lib.schema import Table, Column
 
16
from sqlalchemy.testing import eq_
 
17
from sqlalchemy.testing.schema import Table, Column
17
18
 
18
19
class AttrSettable(object):
19
20
    def __init__(self, **kwargs):
639
640
                                    primary_key=True),
640
641
                Column('category', String(70)))
641
642
 
642
 
    @testing.uses_deprecated("fold_equivalents is deprecated.")
643
643
    def test_manytoone_lazyload(self):
644
644
        """test that lazy load clause to a polymorphic child mapper generates
645
645
        correctly [ticket:493]"""
686
686
        car_join = polymorphic_union(
687
687
            {
688
688
                'car' : cars.outerjoin(offroad_cars).\
689
 
                        select(offroad_cars.c.car_id == None,
690
 
                                fold_equivalents=True),
 
689
                        select(offroad_cars.c.car_id == None).reduce_columns(),
691
690
                'offroad' : cars.join(offroad_cars)
692
691
            }, "type", 'car_join')
693
692