summaryrefslogtreecommitdiff
path: root/test/orm/test_dynamic.py
Commit message (Collapse)AuthorAgeFilesLines
* - major simplification of _collect_update_commands. in particular,Mike Bayer2014-08-181-5/+5
| | | | | | we only call upon the history API fully for primary key columns. We also now skip the whole step of looking at PK columns and using any history at all if no net changes are detected on the object.
* PEP8 tidy of test/orm/test_dynamic.pypr/117Tony Locke2014-07-201-110/+83
|
* Fixes for pg8000 for test/orm/test_dynamic.pyTony Locke2014-07-201-5/+7
|
* - Fixed bug involving dynamic attributes, that was again a regressionMike Bayer2014-06-261-0/+17
| | | | | | of :ticket:`3060` from verision 0.9.5. A self-referential relationship with lazy='dynamic' would raise a TypeError within a flush operation. fixes #3099
* - the raw 2to3 runMike Bayer2013-04-271-14/+14
| | | | - went through examples/ and cleaned out excess list() calls
* - add tests to ensure SELECT of dynamic collection not emittedMike Bayer2012-12-221-21/+170
| | | | | | on regular append/remove history - fix the real cause of the original #2637 issue, backrefs call upon the "pop()" method now which wasn't implemented for Dynamic
* - revert the full iteration of the collection for a passive history event; ↵Mike Bayer2012-12-221-7/+21
| | | | | | | that's the wrong behavior, and for the original #2637 issue we will have to fix the association proxy, which is #2642
* - significantly rework the approach to collection events and history within ↵Mike Bayer2012-12-211-2/+170
| | | | | | | | | | DynamicAttributeImpl - Fixes to the "dynamic" loader on :func:`.relationship`, includes that backrefs will work properly even when autoflush is disabled, history events are more accurate in scenarios where multiple add/remove of the same object occurs, as can often be the case in conjunction with the association proxy. [ticket:2637]
* - cleanup on these testsMike Bayer2012-12-211-358/+202
| | | | - add "extend()" to AppenderQuery
* trying different approaches to test layout. in this one, the testing modulesMike Bayer2012-09-271-5/+5
| | | | | | | become an externally usable package but still remains within the main sqlalchemy parent package. in this system, we use kind of an ugly hack to get the noseplugin imported outside of the "sqlalchemy" package, while still making it available within sqlalchemy for usage by third party libraries.
* - [bug] An error is emitted when uselist=FalseMike Bayer2012-08-051-3/+37
| | | | | is combined with a "dynamic" loader. This is a warning in 0.7.9.
* -whitespace bonanza, contdMike Bayer2012-07-281-7/+7
|
* - move all of orm to use absolute importsMike Bayer2012-06-231-1/+19
| | | | | | | | - break out key mechanics of loading objects into new "orm.loading" module, removing implementation details from both mapper.py and query.py. is analogous to persistence.py - some other cleanup and old cruft removal
* try a between here since 'in' looks for exact matches, doesn't workMike Bayer2011-04-151-2/+2
| | | | with extra thingies in the version
* merge tip + tidyMike Bayer2011-04-151-2/+7
|\
| * Exclude test on MySQL 5.1.49 - 5.1.52.Michael Trier2011-04-151-0/+1
|/ | | | See https://bugs.launchpad.net/ubuntu/+source/mysql-5.1/+bug/706988
* - move all the comments that got shoved below the fixture grabs back upMike Bayer2011-03-271-2/+3
|
* - remove test.sql._base, test.engine._base, test.orm._base, move those ↵Mike Bayer2011-03-271-2/+3
| | | | | | | classes to a new test.lib.fixtures module - move testing.TestBase to test.lib.fixtures - massive search and replace
* - move all the setup_classes(cls) and setup_mappers(cls) to use aMike Bayer2011-03-271-2/+2
| | | | | local cls.Basic, cls.Comparable base class so that there is no ambiguity or hash identity behaviors getting in the way of class registration.
* - remove @testing.resolve_artifact_names, replace with direct attributeMike Bayer2011-03-261-25/+121
| | | | | | | access to the cls/self.tables/classes registries - express orm/_base.py ORMTest in terms of engine/_base.py TablesTest, factor out common steps into TablesTest, remove AltEngineTest as a separate class. will further consolidate these base classes
* change TypeError test to not care about string messageMike Bayer2011-03-151-5/+6
|
* - Session constructor emits a warning when autoflush=TrueMike Bayer2011-02-071-4/+4
| | | | | or expire_on_commit=True when autocommit=True. [ticket:2041]
* - whitespace removal bonanzaMike Bayer2011-01-021-6/+6
|
* - move topological, queue into utilMike Bayer2010-12-051-1/+0
| | | | | - move function_named into test.lib.util - use @decorator for all decorators in test/
* - move sqlalchemy.test to test.libMike Bayer2010-11-151-4/+4
|
* - query.with_parent() now accepts transient objectsMike Bayer2010-09-061-0/+1
| | | | | | | and will use the non-persistent values of their pk/fk attributes in order to formulate the criterion. Docs are also clarified as to the purpose of with_parent(). - fix for PG test executing an alias()
* - Dynamic attributes don't support collectionMike Bayer2010-08-051-1/+13
| | | | | | | | population - added an assertion for when set_committed_value() is called, as well as when joinedload() or subqueryload() options are applied to a dynamic attribute, instead of failure / silent failure. [ticket:1864]
* - The official name for the relation() function is nowMike Bayer2010-03-171-7/+7
| | | | | | relationship(), to eliminate confusion over the relational algebra term. relation() however will remain available in equal capacity for the foreseeable future. [ticket:1740]
* - Using a "dynamic" loader with a "secondary" table now producesMike Bayer2009-10-251-14/+65
| | | | | | | | | | | | a query where the "secondary" table is *not* aliased. This allows the secondary Table object to be used in the "order_by" attribute of the relation(), and also allows it to be used in filter criterion against the dynamic relation. [ticket:1531] - a "dynamic" loader sets up its query criterion at construction time so that the actual query is returned from non-cloning accessors like "statement".
* deprecations per [ticket:1498]:Mike Bayer2009-10-151-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | - deprecated PassiveDefault - use DefaultClause. - the BINARY and MSBinary types now generate "BINARY" in all cases. Omitting the "length" parameter will generate "BINARY" with no length. Use BLOB to generate an unlengthed binary column. - the "quoting='quoted'" argument to MSEnum/ENUM is deprecated. It's best to rely upon the automatic quoting. - "shortname" attribute on bindparam() is removed. - fold_equivalents flag on join is deprecated (will remain until [ticket:1131] is implemented) - "scalar" flag on select() is removed, use select.as_scalar(). - 'transactional' flag on sessionmaker() and others is removed. Use 'autocommit=True' to indicate 'transactional=False'. - 'polymorphic_fetch' argument on mapper() is removed. Loading can be controlled using the 'with_polymorphic' option. - 'select_table' argument on mapper() is removed. Use 'with_polymorphic=("*", <some selectable>)' for this functionality. - 'proxy' argument on synonym() is removed. This flag did nothing throughout 0.5, as the "proxy generation" behavior is now automatic. - Passing a single list of elements to eagerload(), eagerload_all(), contains_eager(), lazyload(), defer(), and undefer() instead of multiple positional -args is deprecated. - Passing a single list of elements to query.order_by(), query.group_by(), query.join(), or query.outerjoin() instead of multiple positional *args is deprecated. - query.iterate_instances() is removed. Use query.instances(). - Query.query_from_parent() is removed. Use the sqlalchemy.orm.with_parent() function to produce a "parent" clause, or alternatively query.with_parent(). - query._from_self() is removed, use query.from_self() instead. - the "comparator" argument to composite() is removed. Use "comparator_factory". - RelationProperty._get_join() is removed. - the 'echo_uow' flag on Session is removed. Use logging on the "sqlalchemy.orm.unitofwork" name. - session.clear() is removed. use session.expunge_all(). - session.save(), session.update(), session.save_or_update() are removed. Use session.add() and session.add_all(). - the "objects" flag on session.flush() remains deprecated. - the "dont_load=True" flag on session.merge() is deprecated in favor of "load=False". - passing an InstanceState (internal SQLAlchemy state object) to attributes.init_collection() or attributes.get_history() is deprecated. These functions are public API and normally expect a regular mapped object instance. - the 'engine' parameter to declarative_base() is removed. Use the 'bind' keyword argument.
* assert -> eq_Philip Jenvey2009-08-291-49/+54
|
* - renamed PASSIVE_NORESULT to PASSIVE_NO_RESULTMike Bayer2009-08-071-1/+1
| | | | | | | | | | | | | | | | - renamed PASSIVE_NO_CALLABLES to PASSIVE_NO_FETCH - passive now propagates all the way through lazy callables, all the way into query._get(), so that many-to-one lazy load can load the instance via the local session but not trigger any SQL if not available, fixes [ticket:1298] without messing up consistency of tests added in r6201 - many-to-one also handles returning PASSIVE_NO_RESULT for the "old" value thus eliminating the need for the previous value even if the new value is None - query._get() uses identity_map.get(), which has been changed to no longer raise KeyError, thus providing mythical time savings that didn't seem to make any difference in how fast the unit tests ran.
* merge 0.6 series to trunk.Mike Bayer2009-08-061-5/+5
|
* - unit tests have been migrated from unittest to nose.Mike Bayer2009-06-101-0/+561
See README.unittests for information on how to run the tests. [ticket:970]