summaryrefslogtreecommitdiff
path: root/lib/sqlalchemy/testing/suite
Commit message (Collapse)AuthorAgeFilesLines
* - document / work around that dialect_options isn't necessarily thereMike Bayer2014-12-051-0/+2
|
* - The :meth:`.PGDialect.has_table` method will now query againstMike Bayer2014-12-041-0/+4
| | | | | | | | | | | ``pg_catalog.pg_table_is_visible(c.oid)``, rather than testing for an exact schema match, when the schema name is None; this so that the method will also illustrate that temporary tables are present. Note that this is a behavioral change, as Postgresql allows a non-temporary table to silently overwrite an existing temporary table of the same name, so this changes the behavior of ``checkfirst`` in that unusual scenario. fixes #3264
* add more order by hereMike Bayer2014-10-111-1/+1
|
* - change this literal so that the bound name doesn't have a numericMike Bayer2014-10-111-2/+2
| | | | name, this is sort of a bug for oracle
* - :meth:`.Insert.from_select` now includes Python and SQL-expressionMike Bayer2014-10-101-1/+36
| | | | | | | defaults if otherwise unspecified; the limitation where non- server column defaults aren't included in an INSERT FROM SELECT is now lifted and these expressions are rendered as constants into the SELECT statement.
* Merge branch 'reflect-unique-constraints' of ↵Mike Bayer2014-10-041-4/+9
|\ | | | | | | https://bitbucket.org/jerdfelt/sqlalchemy into pr30
| * Reflect unique constraints when reflecting a Table objectJohannes Erdfelt2014-09-171-4/+9
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Calls to reflect a table did not create any UniqueConstraint objects. The reflection core made no calls to get_unique_constraints and as a result, the sqlite dialect would never reflect any unique constraints. MySQL transparently converts unique constraints into unique indexes, but SQLAlchemy would reflect those as an Index object and as a UniqueConstraint. The reflection core will now deduplicate the unique constraints. PostgreSQL would reflect unique constraints as an Index object and as a UniqueConstraint object. The reflection core will now deduplicate the unique indexes.
* | - Added support for the Oracle table option ON COMMIT. This is beingMike Bayer2014-09-171-5/+17
|/ | | | | | | | | kept separate from Postgresql's ON COMMIT for now even though ON COMMIT is in the SQL standard; the option is still very specific to temp tables and we eventually would provide a more first class temporary table feature. - oracle can apparently do get_temp_table_names() too, so implement that, fix its get_table_names(), and add it to #3204. fixes #3204 again.
* - Added :meth:`.Inspector.get_temp_table_names` andMike Bayer2014-09-171-0/+78
| | | | | | | | | | | | :meth:`.Inspector.get_temp_view_names`; currently, only the SQLite dialect supports these methods. The return of temporary table and view names has been **removed** from SQLite's version of :meth:`.Inspector.get_table_names` and :meth:`.Inspector.get_view_names`; other database backends cannot support this information (such as MySQL), and the scope of operation is different in that the tables can be local to a session and typically aren't supported in remote schemas. fixes #3204
* - ensure literal_binds works with LIMIT clause, FOR UPDATEMike Bayer2014-09-031-0/+15
|
* - use configured test_schema hereMike Bayer2014-08-081-12/+14
|
* - apply pep8 formatting to sqlalchemy/sql, sqlalchemy/util, sqlalchemy/dialects,Brian Jarrett2014-07-208-267/+261
| | | | sqlalchemy/orm, sqlalchemy/event, sqlalchemy/testing
* Merge branch 'master' of https://github.com/BY-jk/sqlalchemyMike Bayer2014-06-081-1/+1
|\
| * Wrong type usagepr/95BY-jk2014-05-301-1/+1
| | | | | | Wrong Type (TEXT) being used in StringTest
* | - more tests, including backend testsMike Bayer2014-05-161-1/+79
| | | | | | | | - implement for SQL server, use window functions when simple limit/offset not available
* | Documentation fix-up: "its" vs. "it's"pr/91Matthias Urlichs2014-05-111-1/+1
|/ | | | | | | | | Removed ungrammatical apostrophes from documentation, replacing "it's" with "its" where appropriate (but in a few cases with "it is" when that read better). While doing that, I also fixed a couple of minor typos etc. as I noticed them.
* - Tweaked the settings for mysql-connector-python; in Py2K, theMike Bayer2014-03-271-1/+1
| | | | | | | | | | | "supports unicode statements" flag is now False, so that SQLAlchemy will encode the *SQL string* (note: *not* the parameters) to bytes before sending to the database. This seems to allow all unicode-related tests to pass for mysql-connector, including those that use non-ascii table/column names, as well as some tests for the TEXT type using unicode under cursor.executemany(). - other mysql-connector fixes; latest version seems to do better on function call counts
* Added missing text_type requirement to TextTestStefan Reich2014-03-271-0/+1
| | | | | Conflicts: lib/sqlalchemy/testing/suite/test_types.py
* - rename __multiple__ to __backend__, and apply __backend__ to a large ↵Mike Bayer2014-03-248-27/+27
| | | | | | number of tests. - move out logging tests from test_execute to test_logging
* - Added support for literal rendering of boolean values, e.g.Mike Bayer2014-03-131-2/+71
| | | | | "true" / "false" or "1" / "0". - added Boolean tests to the test suite
* commentMike Bayer2014-03-131-0/+7
|
* - add a suite test for underscore as initial charMike Bayer2014-03-131-0/+14
|
* - add more support for suite tests, moving some tests from test_query out to ↵Mike Bayer2014-03-131-6/+149
| | | | | | suite and adding some more requirements
* - Support has been added for pytest to run tests. This runnerMike Bayer2014-03-038-1/+33
| | | | | | | | | | | | | | | | | | | | | | | | | | is currently being supported in addition to nose, and will likely be preferred to nose going forward. The nose plugin system used by SQLAlchemy has been split out so that it works under pytest as well. There are no plans to drop support for nose at the moment and we hope that the test suite itself can continue to remain as agnostic of testing platform as possible. See the file README.unittests.rst for updated information on running tests with pytest. The test plugin system has also been enhanced to support running tests against mutiple database URLs at once, by specifying the ``--db`` and/or ``--dburi`` flags multiple times. This does not run the entire test suite for each database, but instead allows test cases that are specific to certain backends make use of that backend as the test is run. When using pytest as the test runner, the system will also run specific test suites multiple times, once for each database, particularly those tests within the "dialect suite". The plan is that the enhanced system will also be used by Alembic, and allow Alembic to run migration operation tests against multiple backends in one run, including third-party backends not included within Alembic itself. Third party dialects and extensions are also encouraged to standardize on SQLAlchemy's test suite as a basis; see the file README.dialects.rst for background on building out from SQLAlchemy's test platform.
* - add new tests for individual type reflectionMike Bayer2014-03-011-0/+46
|
* use view_column requirement hereMike Bayer2014-02-281-3/+3
|
* - dont create a self-ref FK if test suite marked as not supporting self refMike Bayer2014-02-281-13/+15
| | | | | - break out reflection of views to support view column reflection separately from view definition
* - repair signature for base get_unique_constraints() methodMike Bayer2014-01-201-0/+1
| | | | - test_autoincrement_col still needs reflection overall
* - apply a similar fix for floats to mssql+pyodbc as we did to firebirdMike Bayer2013-12-281-4/+20
| | | | | - wrangle through osx+pyodbc+freetds to get at least test_suite to pass again with mssql+pyodbc. invovled adding some silly requirements
* - fix the insert from select test to use a non-autoinc tableMike Bayer2013-12-281-4/+8
|
* - actually check the list of views!Mike Bayer2013-12-271-0/+1
|
* - add a test which creates tables and views at the same time, then tests ↵Mike Bayer2013-12-271-0/+6
| | | | | | that the lists of each can be reflected independently. Testing [ticket:2898] at the moment.
* - repair some suite tests for firebirdMike Bayer2013-12-271-1/+15
|
* - The precision used when coercing a returned floating point value toMike Bayer2013-11-221-0/+10
| | | | | | | | | | Python ``Decimal`` via string is now configurable. The flag ``decimal_return_scale`` is now supported by all :class:`.Numeric` and :class:`.Float` types, which will ensure this many digits are taken from the native floating point value when it is converted to string. If not present, the type will make use of the value of ``.scale``, if the type supports this setting and it is non-None. Otherwise the original default length of 10 is used. [ticket:2867]
* - use a different approach here since oracle isn't doing it either, just ↵Mike Bayer2013-10-211-3/+6
| | | | round it
* - oursql returns a pure FP here which isn't exactMike Bayer2013-10-211-1/+2
|
* - The typing system now handles the task of rendering "literal bind" values,Mike Bayer2013-10-201-7/+94
| | | | | | | | | | | | | | | e.g. values that are normally bound parameters but due to context must be rendered as strings, typically within DDL constructs such as CHECK constraints and indexes (note that "literal bind" values become used by DDL as of :ticket:`2742`). A new method :meth:`.TypeEngine.literal_processor` serves as the base, and :meth:`.TypeDecorator.process_literal_param` is added to allow wrapping of a native literal rendering method. [ticket:2838] - enhance _get_colparams so that we can send flags like literal_binds into INSERT statements - add support in PG for inspecting standard_conforming_strings - add a new series of roundtrip tests based on INSERT of literal plus SELECT for basic literal rendering in dialect suite
* - assorted fixes raised by pypy 2.1beta2, but all of which are goodMike Bayer2013-08-011-2/+3
| | | | | | | | | | | | | | | ideas in general: - pypy2.1 w/ sqlite3 is the first DBAPI we're seeing returning unicode in cursor.description without being py3k. add a new on-connect check for this, if we get back a u"", just don't do description decoding, should be OK for now. - the set tests in test_collection were assuming the two sets would be ordered the same when it tested pop(), can't really assume that. - test_serializer gets worse and worse, pickle is just not really viable here, ding out pypy - pypy2.1b2 seems to allow cursor.lastrowid to work (or we changed something?) - pool._threadconns.current() is a weakref, it can be None - another one of those logging.handlers imports
* - use inline=True for the insert..select here so it works on oracleMike Bayer2013-07-121-2/+2
|
* - Added new method to the :func:`.insert` constructMike Bayer2013-07-051-0/+28
| | | | | | | | | | :meth:`.Insert.from_select`. Given a list of columns and a selectable, renders ``INSERT INTO (table) (columns) SELECT ..``. While this feature is highlighted as part of 0.9 it is also backported to 0.8.3. [ticket:722] - The :func:`.update`, :func:`.insert`, and :func:`.delete` constructs will now interpret ORM entities as FROM clauses to be operated upon, in the same way that select() already does. Also in 0.8.3.
* add a float exclusion to help oursql build 100%Mike Bayer2013-07-021-0/+1
|
* Fix indexes reflection in PostgreSQLpr/13Roman Podolyaka2013-06-261-1/+6
| | | | | | Reflection of indexes must preserve the order of columns. Fixes issue 2767.
* Merge pull request #11 from malor/fix_uc_reflectionmike bayer2013-06-231-3/+8
|\ | | | | Fix unique constraints reflection in SQLite and PostgreSQL
| * Fix unique constraints reflection in PostgreSQLpr/11Roman Podolyaka2013-06-231-2/+2
| | | | | | | | Reflection of unique constraints must preserve the order of columns.
| * Fix unique constraints reflection in SQLiteRoman Podolyaka2013-06-231-0/+4
| | | | | | | | | | | | | | If SQLite keywords are used as column names, they are quoted. The code parsing the information about table unique constraints should be modified so that it properly removes double-quotes from column names.
| * Improve _test_get_unique_constraints()Roman Podolyaka2013-06-231-1/+2
| | | | | | | | | | | | Call eq_() in a loop instead of comparing two lists directly. This makes it much easier to find out which element is not equal to the reference value.
* | Fix unicode literals on Python 3.1 and 3.2pr/10Roman Podolyaka2013-06-231-1/+2
|/ | | | | A few tests use u'' unicode literals which are not supported in Python versions 3.1 and 3.2.
* - get_unique_constraints() pull requestMike Bayer2013-06-091-1/+44
| | | | | | - version (0.9 for now) - changelog - move the test into the test suite so that all dialects can take advantage of it
* Merge branch 'master' into ticket_1068Mike Bayer2013-06-033-13/+14
|\
| * fix the unicode test suiteMike Bayer2013-05-261-7/+8
| |