summaryrefslogtreecommitdiff
path: root/test/orm/dynamic.py
Commit message (Collapse)AuthorAgeFilesLines
* - unit tests have been migrated from unittest to nose.Mike Bayer2009-06-101-559/+0
| | | | | See README.unittests for information on how to run the tests. [ticket:970]
* Modified query_cls on DynamicAttribteImpl to accept a full mixin version of ↵Michael Trier2009-04-251-20/+59
| | | | the AppenderQuery.
* - Fixed the "set collection" function on "dynamic" relationsMike Bayer2009-03-271-4/+63
| | | | | | | | to initiate events correctly. Previously a collection could only be assigned to a pending parent instance, otherwise modified events would not be fired correctly. Set collection is now compatible with merge(), fixes [ticket:1352].
* more testsrel_0_5_3Mike Bayer2009-03-241-2/+14
|
* - Fixed bug in dynamic_loader() where append/remove eventsMike Bayer2009-03-241-1/+28
| | | | | after construction time were not being propagated to the UOW to pick up on flush(). [ticket:1347]
* - The "clear()", "save()", "update()", "save_or_update()"Mike Bayer2009-01-171-4/+4
| | | | | | Session methods have been deprecated, replaced by "expunge_all()" and "add()". "expunge_all()" has also been added to ScopedSession.
* - query.order_by() accepts None which will remove any pendingMike Bayer2009-01-031-0/+12
| | | | | | | order_by state from the query, as well as cancel out any mapper/relation configured ordering. This is primarily useful for overriding the ordering specified on a dynamic_loader(). [ticket:1079]
* dynamic_loader() accepts query_class= to mix in user Query subclasses.Jason Kirtland2008-12-181-1/+27
|
* Modified fails_on testing decorator to take a reason for the failure.Michael Trier2008-12-121-3/+3
| | | | | This should assist with helping to document the reasons for testing failures. Currently unspecified failures are defaulted to 'FIXME: unknown'.
* A few more order_by statements added to the tests in order to please msql ↵Michael Trier2008-11-261-3/+3
| | | | when using offsets.
* - renamed autoexpire to expire_on_commitMike Bayer2008-08-031-1/+1
| | | | | - renamed SessionTransaction autoflush to reentrant_flush to more clearly state its purpose - added _enable_transaction_accounting, flag for Mike Bernson which disables the whole 0.5 transaction state management; the system depends on expiry on rollback in order to function.
* - A critical fix to dynamic relations allows theMike Bayer2008-07-191-2/+16
| | | | | "modified" history to be properly cleared after a flush().
* Chipping away at remaining cruft.Jason Kirtland2008-05-101-10/+9
|
* Test suite modernization in progress. Big changes:Jason Kirtland2008-05-091-57/+79
| | | | | | | | | | | - @unsupported now only accepts a single target and demands a reason for not running the test. - @exclude also demands an exclusion reason - Greatly expanded @testing.requires.<feature>, eliminating many decorators in the suite and signficantly easing integration of multi-driver support. - New ORM test base class, and a featureful base for mapped tests - Usage of 'global' for shared setup going away, * imports as well
* r4695 merged to trunk; trunk now becomes 0.5.Mike Bayer2008-05-091-0/+18
| | | | 0.4 development continues at /sqlalchemy/branches/rel_0_4
* - merged -r4458:4466 of query_columns branchMike Bayer2008-04-071-3/+3
| | | | | | | - this branch changes query.values() to immediately return an iterator, adds a new "aliased" construct which will be the primary method to get at aliased columns when using values() - tentative ORM versions of _join and _outerjoin are not yet public, would like to integrate with Query better (work continues in the branch) - lots of fixes to expressions regarding cloning and correlation. Some apparent ORM bug-workarounds removed. - to fix a recursion issue with anonymous identifiers, bind parameters generated against columns now just use the name of the column instead of the tablename_columnname label (plus the unique integer counter). this way expensive recursive schemes aren't needed for the anon identifier logic. This, as usual, impacted a ton of compiler unit tests which needed a search-n-replace for the new bind names.
* - fixed/added coverage for various cascade scenariosMike Bayer2008-03-181-1/+11
| | | | | - added coverage for some extra cases in dynamic relations - removed some unused methods from unitofwork
* - fixed "cascade delete" operation of dynamic relations,Mike Bayer2008-03-161-1/+37
| | | | | | which had only been implemented for foreign-key nulling behavior in 0.4.2 and not actual cascading deletes [ticket:895]
* - dynamic_loader() / lazy="dynamic" now accepts and usesMike Bayer2008-03-091-0/+8
| | | | | the order_by parameter in the same way in which it works with relation().
* added sanity test for order_byMike Bayer2008-03-091-1/+9
|
* - Restored 2.3 compat. in lib/sqlalchemyJason Kirtland2008-01-191-8/+8
| | | | | | | - Part one of test suite fixes to run on 2.3 Lots of failures still around sets; sets.Set differs from __builtin__.set particularly in the binops. We depend on set extensively now and may need to provide a corrected sets.Set subclass on 2.3.
* - dynamic relations, when referenced, create a strongMike Bayer2008-01-161-0/+52
| | | | | | | reference to the parent object so that the query still has a parent to call against even if the parent is only created (and otherwise dereferenced) within the scope of a single expression [ticket:938]
* - testbase is gone, replaced by testenvJason Kirtland2008-01-121-17/+16
| | | | | | - Importing testenv has no side effects- explicit functions provide similar behavior to the old immediate behavior of testbase - testing.db has the configured db - Fixed up the perf/* scripts
* - also with dynamic, implemented correct count() behavior as wellMike Bayer2007-12-071-0/+8
| | | | as other helper methods.
* - added "cascade delete" behavior to "dynamic" relations just likeMike Bayer2007-12-071-1/+22
| | | | | | that of regular relations. if passive_deletes flag (also just added) is not set, a delete of the parent item will trigger a full load of the child items so that they can be deleted or updated accordingly.
* - fixed endless loop issue when using lazy="dynamic" on bothMike Bayer2007-11-191-2/+18
| | | | sides of a bi-directional relationship [ticket:872]
* - session.refresh() and session.expire() now support an additional argumentMike Bayer2007-11-181-5/+3
| | | | | | | | | | | | | | "attribute_names", a list of individual attribute keynames to be refreshed or expired, allowing partial reloads of attributes on an already-loaded instance. - finally simplified the behavior of deferred attributes, deferred polymorphic load, session.refresh, session.expire, mapper._postfetch to all use a single codepath through query._get(), which now supports a list of individual attribute names to be refreshed. the *one* exception still remaining is mapper._get_poly_select_loader(), which may stay that way since its inline with an already processing load operation. otherwise, query._get() is the single place that all "load this instance's row" operation proceeds. - cleanup all over the place
* Migrated maxdb behavioral assumptions from unsupported to fails_onJason Kirtland2007-11-051-16/+18
|
* - removed __len__ from "dynamic" collection as it would require issuingMike Bayer2007-10-171-0/+13
| | | | | a SQL "count()" operation, thus forcing all list evaluations to issue redundant SQL [ticket:818]
* change the in_ API to accept a sequence or a selectable [ticket:750]Ants Aasma2007-10-161-1/+1
|
* Deleting an entity having a dynamic loader with cascade="all" has some ↵Jason Kirtland2007-08-221-1/+3
| | | | issues at the moment.
* 1. Module layout. sql.py and related move into a package called "sql".Mike Bayer2007-08-181-1/+0
| | | | | | | | | | | | 2. compiler names changed to be less verbose, unused classes removed. 3. Methods on Dialect which return compilers, schema generators, identifier preparers have changed to direct class references, typically on the Dialect class itself or optionally as attributes on an individual Dialect instance if conditional behavior is needed. This takes away the need for Dialect subclasses to know how to instantiate these objects, and also reduces method overhead by one call for each one. 4. as a result of 3., some internal signatures have changed for things like compiler() (now statement_compiler()), preparer(), etc., mostly in that the dialect needs to be passed explicitly as the first argument (since they are just class references now). The compiler() method on Engine and Connection is now also named statement_compiler(), but as before does not take the dialect as an argument. 5. changed _process_row function on RowProxy to be a class reference, cuts out 50K method calls from insertspeed.py
* - moved test/orm/fixtures.py to testlibMike Bayer2007-08-161-1/+1
| | | | | | | - flattened mapper calls in _instance() to operate directly through a default MapperExtension - more tests for ScopedSession, fixed [ticket:746] - threadlocal engine propagates **kwargs through begin()
* - added 'object_session' as classlevel method to SessionMike Bayer2007-08-091-2/+2
| | | | | | | - moved 'identity_key' to be a classmethod on Session - some docstrings - merged r3229 from 0.3 branch to unconditonally quote schemaname in PG-reflected default - name fixes in dynamic unit test
* - removed import of old sqlite module [ticket:654]Mike Bayer2007-07-291-1/+1
| | | | | - removed sqlite version warning, all tests pass 100% with py2.5's older sqlite lib - fixed dynamic test for py2.5
* - trimming down redundancy in lazyloader codeMike Bayer2007-07-281-56/+86
| | | | | | | - fixups to ORM test fixture code - fixup to dynamic realtions, test for autoflush session, delete-orphan - made new dynamic_loader() function to create them - removed old hasparent() call on AttributeHistory
* Got basic backrefs going with dynamic attributesJason Kirtland2007-07-281-4/+74
|
* - an experimental feature that combines a Query with an ↵Mike Bayer2007-07-271-0/+59
InstrumentedAttribute, to provide "always live" results in conjunction with mutator capability