diff options
| author | Renato Massaro <renato@hackerexperience.com> | 2015-07-14 15:42:46 -0300 |
|---|---|---|
| committer | Renato Massaro <renato@hackerexperience.com> | 2015-07-14 15:42:46 -0300 |
| commit | f272a4d92295d69446aea712e2927c1c731d0e6c (patch) | |
| tree | 7d3866744f4333eca78f35db6c197f20f38061c1 /test | |
| parent | b68c9ac93eea62a1f4ae2c0701e5af7c432e9432 (diff) | |
| download | sqlalchemy-pr/187.tar.gz | |
Add basic LTREE support; missing testspr/187
Diffstat (limited to 'test')
| -rw-r--r-- | test/dialect/postgresql/test_types.py | 14 |
1 files changed, 13 insertions, 1 deletions
diff --git a/test/dialect/postgresql/test_types.py b/test/dialect/postgresql/test_types.py index fac0f2df8..456efbf92 100644 --- a/test/dialect/postgresql/test_types.py +++ b/test/dialect/postgresql/test_types.py @@ -14,7 +14,7 @@ import sqlalchemy as sa from sqlalchemy.dialects.postgresql import base as postgresql from sqlalchemy.dialects.postgresql import HSTORE, hstore, array, \ INT4RANGE, INT8RANGE, NUMRANGE, DATERANGE, TSRANGE, TSTZRANGE, \ - JSON, JSONB + JSON, JSONB, LTREE, LQUERY, LTXTQUERY import decimal from sqlalchemy import util from sqlalchemy.testing.util import round_decimal @@ -1052,6 +1052,18 @@ class TimestampTest(fixtures.TestBase, AssertsExecutionResults): eq_(result[0], datetime.datetime(2007, 12, 25, 0, 0)) +class LTreeTest(fixtures.TestBase, AssertsExecutionResults): + __only_on__ = 'postgresql >= 9.1.0' + __backend__ = True + + def test_ltree(self): + engine = testing.db + connection = engine.connect() + + # The Postgresql server must have the LTREE extension enabled. + # `CREATE EXTENSION ltree;` + + class SpecialTypesTest(fixtures.TestBase, ComparesTables, AssertsCompiledSQL): """test DDL and reflection of PG-specific types """ |
