Commit Graph

128 Commits

Author SHA1 Message Date
Mike Bayer f77c9f950f disabling triggers for Mysql since it requires SUPER privs 2009-04-05 02:29:45 +00:00
Mike Bayer 290ff9930a - coverage dumps out separate reports for individual packages
- other coverage tips
2009-03-29 20:23:05 +00:00
Mike Bayer a3ab10c3f3 - removed 2.3 compat stuff
- updated MANIFEST for the newer build
2009-01-06 18:19:59 +00:00
Michael Trier 4e8a817ac2 A few 2.3 cleanup items. 2008-12-30 06:24:59 +00:00
Michael Trier 12307ecbcf Pulled callable into testlib because path fixup is not available at the point we need it. 2008-12-21 00:47:04 +00:00
Mike Bayer 5ddce0ea00 *most* py3k warnings are resolved, with the exception of the various __setslice__ related warnings
I don't really know how to get rid of
2008-12-18 18:46:27 +00:00
Mike Bayer d76dc73f33 merge the test/ directory from -r5438:5439 of py3k_warnings branch. this gives
us a 2.5-frozen copy of unittest so we're insulated from unittest changes.
2008-12-18 18:11:12 +00:00
Mike Bayer be5d326343 merged -r5299:5438 of py3k warnings branch. this fixes some sqlite py2.6 testing issues,
and also addresses a significant chunk of py3k deprecations.  It's mainly
expicit __hash__ methods.  Additionally, most usage of sets/dicts to store columns uses
util-based placeholder names.
2008-12-18 17:57:15 +00:00
Michael Trier 1d90146210 Modified fails_on testing decorator to take a reason for the failure.
This should assist with helping to document the reasons for testing failures.
Currently unspecified failures are defaulted to 'FIXME: unknown'.
2008-12-12 03:41:05 +00:00
Michael Trier 8ffbc9a846 Access doesn't support savepoints or two-phase commit. 2008-12-11 19:24:24 +00:00
Michael Trier 052d7f3643 Implemented experimental savepoint support in mssql. There are still some failing savepoint related tests. 2008-12-11 19:24:22 +00:00
Mike Bayer 5b0c456abd fix circular import 2008-12-11 18:43:05 +00:00
Mike Bayer f527d3b9af - PickleType now favors == comparison by default,
if the incoming object (such as a dict) implements
__eq__().  If the object does not implement
__eq__() and mutable=True, a deprecation warning
is raised.
2008-12-11 17:27:33 +00:00
Mike Bayer a2f90fd003 - reworked the "SQL assertion" code to something more flexible and based off of ConnectionProxy. upcoming changes to dependency.py
will make use of the enhanced flexibility.
2008-12-10 02:16:52 +00:00
Mike Bayer c136b7a6e9 - Improved mapper() check for non-class classes.
[ticket:1236]
2008-12-01 22:09:15 +00:00
Mike Bayer 3e486caaab - switched session.save() to session.add() throughout declarative test
- Fixed PendingDeprecationWarning involving order_by
parameter on relation(). [ticket:1226]
- Unit tests still filter pending deprecation warnings but have a commented-out
line to temporarily disable this behavior.  Tests need to be fully converted
before we can turn this on.
2008-11-14 18:57:24 +00:00
Mike Bayer 0cff22720b - Removed the 'properties' attribute of the
Connection object, Connection.info should be used.
- Method consoliation in Connection, ExecutionContext
2008-11-09 19:32:25 +00:00
Mike Bayer 1901519fa7 removed setup_instance() from the public API
of ClassManager, and made it a private method on
_ClassInstrumentationAdapter.  ClassManager's approach
handles the default task with fewer function calls which chops off
a few hundred calls from the pertinent profile tests.
2008-11-08 21:00:15 +00:00
Mike Bayer 1ccdfb5172 call count pinata party 2008-10-23 02:22:57 +00:00
Mike Bayer 6f60e76883 - The 'length' argument to all Numeric types has been renamed
to 'scale'.  'length' is deprecated and is still accepted
with a warning. [ticket:827]
- The 'length' argument to MSInteger, MSBigInteger, MSTinyInteger,
MSSmallInteger and MSYear has been renamed to 'display_width'.
[ticket:827]
- mysql._Numeric now consumes 'unsigned' and 'zerofill' from
the given kw, so that the same kw can be passed along to Numeric
and allow the 'length' deprecation logic to still take effect
- added testlib.engines.all_dialects() to return a dialect for
every db module
- informix added to sqlalchemy.databases.__all__.  Since other
"experimental" dbs like access and sybase are there, informix
should be as well.
2008-08-24 19:52:54 +00:00
Mike Bayer 427ed1966f - fixed a bug in declarative test which was looking for old version of history
- Added "sorted_tables" accessor to MetaData, which returns
Table objects sorted in order of dependency as a list.
This deprecates the MetaData.table_iterator() method.
The "reverse=False" keyword argument has also been
removed from util.sort_tables(); use the Python
'reversed' function to reverse the results.
[ticket:1033]
2008-08-19 21:27:34 +00:00
Mike Bayer 50c4825b54 merged r5018 from 0.4 branch, but using contextual_connect() (will fix in 0.4 too) 2008-08-10 05:26:16 +00:00
Jason Kirtland 8fa48edbf9 - Removed 2.3 set emulations/enhancements.
(sets.Set-based collections & DB-API returns still work.)
2008-07-15 19:23:52 +00:00
Michael Trier 36e7efa4eb Fixed borked testlib due to r4901. 2008-07-08 02:48:13 +00:00
Michael Trier cec5947b5b Refactored the mock_engine in the tests so it's not duplicated in several places. Closes #1098 2008-07-08 01:37:38 +00:00
Jason Kirtland 938badb2bb - Fleshed out Session.get_bind(), generating a couple todos: [ticket:1053], [ticket:1054], [ticket:1055]
- Trotted out util.pending_deprecation, replacing some 'TODO: deprecate's
- Big session docstring content edit fiesta
- session.py line length and whitespace non-fiesta
2008-05-20 21:44:43 +00:00
Jason Kirtland 8e9fce417a Split out a couple true autoincrement/identity tests from emulated-with-sequences autoincrement=True tests. 2008-05-19 23:15:41 +00:00
Mike Bayer b3102a097a - changed char_length() to use a fake, neutral "generic function"
- assert_compile() reports the dialect in use
2008-05-19 22:46:14 +00:00
Jason Kirtland ced326dc1f - Implemented generic CHAR_LENGTH for sqlite (-> LENGTH())
- Updated .requires for firebird
2008-05-19 19:37:44 +00:00
Lele Gaifax d415a8edd4 Minor doc fixes 2008-05-15 00:07:32 +00:00
Jason Kirtland dd20ca5cb9 - Removed @unsupported 2008-05-14 22:09:23 +00:00
Jason Kirtland 65f4f02ec8 Columns now have default= and server_default=. PassiveDefault fades away. 2008-05-14 19:49:40 +00:00
Jason Kirtland 6524df9214 Removed: all legacy users migrated. 2008-05-13 17:44:49 +00:00
Jason Kirtland b97c8f2d60 - Reworked test/orm/mapper
- Exposed some uncovered (and broken) functionality
- Fixed [ticket:1038]
2008-05-13 16:39:47 +00:00
Lele Gaifax a11b5fc176 Support for under Firebird 2008-05-13 09:31:30 +00:00
Mike Bayer 9d700bc60c correcting dataload profiles for various tests 2008-05-10 18:38:20 +00:00
Jason Kirtland e41c0f4107 Test suite modernization in progress. Big changes:
- @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
2008-05-09 20:26:09 +00:00
Mike Bayer 4a6afd469f r4695 merged to trunk; trunk now becomes 0.5.
0.4 development continues at /sqlalchemy/branches/rel_0_4
2008-05-09 16:34:10 +00:00
Jason Kirtland 49895a84fd Expanded --noncomparable to cover all comparision ops 2008-04-25 20:44:02 +00:00
Jason Kirtland 28ecb49eac - Avoid cProfile on 2.4 (available via lsprof?) 2008-04-07 22:17:42 +00:00
Mike Bayer e3b2305d67 - merged -r4458:4466 of query_columns branch
- 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.
2008-04-07 01:12:44 +00:00
Jason Kirtland d78f39d005 - Experimental: prefer cProfile over hotspot for 2.5+
- The latest skirmish in the battle against zoomark and sanity:
  3rd party code is factored out in the function call count canary tests
2008-04-03 17:08:08 +00:00
Mike Bayer cfd7807838 some test fixup for oracle 2008-04-02 16:12:07 +00:00
Mike Bayer 61d8644320 - added verbose activity to profiling.function_call_count
- simplified oracle non-ansi join generation, removed hooks from base compiler
- removed join() call from _label generation, fixed repeat label gen
2008-04-01 22:36:40 +00:00
Jason Kirtland b93eb67f4b - Squashed 2.4 generators. 2008-04-01 18:31:20 +00:00
Mike Bayer ad231da3b8 - merge() may actually work now, though we've heard that before...
- merge() uses the priamry key attributes on the object if _instance_key not present.  so merging works for instances that dont have an instnace_key, will still issue UPDATE for existing rows.
- improved collection behavior for merge() - will remove elements from a destination collection that are not in the source.
- fixed naive set-mutation issue in Select._get_display_froms
- simplified fixtures.Base a bit
2008-04-01 17:13:09 +00:00
Mike Bayer c4955c05a3 - merged with_polymorphic branch, which was merged with query_columns branch
- removes everything to do with select_table, which remains as a keyword argument synonymous with
with_polymorphic=('*', select_table).
- all "polymorphic" selectables find their way to Query by way of _set_select_from() now, so that
all joins/aliasing/eager loads/etc. is handled consistently.  Mapper has methods for producing
polymorphic selectables so that Query and eagerloaders alike can get to them.
- row aliasing simplified, so that they don't need to nest.  they only need the source selectable
and adapt to whatever incoming columns they get.
- Query is more egalitarian about mappers/columns now.  Still has a strong sense of "entity zero",
but also introduces new unpublished/experimental _values() method which sets up a columns-only query.
- Query.order_by() and Query.group_by() take *args now (also still take a list, will likely deprecate
in 0.5).  May want to do this for select() as well.
- the existing "check for False discriminiator" "fix" was not working completely, added coverage
- orphan detection was broken when the target object was a subclass of the mapper with the orphaned
relation, fixed that too.
2008-03-29 00:00:49 +00:00
Mike Bayer 82198afee9 - the "owner" keyword on Table is now deprecated, and is
exactly synonymous with the "schema" keyword.  Tables
      can now be reflected with alternate "owner" attributes,
      explicitly stated on the Table object or not using
      "schema".

    - all of the "magic" searching for synonyms, DBLINKs etc.
      during table reflection
      are disabled by default unless you specify
      "oracle_resolve_synonyms=True" on the Table object.
      Resolving synonyms necessarily leads to some messy
      guessing which we'd rather leave off by default.
      When the flag is set, tables and related tables
      will be resolved against synonyms in all cases, meaning
      if a synonym exists for a particular table, reflection
      will use it when reflecting related tables.  This is
      stickier behavior than before which is why it's
      off by default.
2008-03-22 19:30:42 +00:00
Catherine Devlin 6d5cb2522b Undoing patch #994, for now; more testing needed. Sorry. Also modifying test for query equivalence to account for underscoring of bind variables. 2008-03-20 16:48:46 +00:00
Catherine Devlin 04b81eecba added a runtime-incrementing counter for default primary keys to testlib/schema for Oracle 2008-03-19 22:53:31 +00:00