summaryrefslogtreecommitdiff
path: root/lib/sqlalchemy/testing/suite/test_select.py
diff options
context:
space:
mode:
Diffstat (limited to 'lib/sqlalchemy/testing/suite/test_select.py')
-rw-r--r--lib/sqlalchemy/testing/suite/test_select.py15
1 files changed, 15 insertions, 0 deletions
diff --git a/lib/sqlalchemy/testing/suite/test_select.py b/lib/sqlalchemy/testing/suite/test_select.py
index 3f14ada05..68dadd0a9 100644
--- a/lib/sqlalchemy/testing/suite/test_select.py
+++ b/lib/sqlalchemy/testing/suite/test_select.py
@@ -136,6 +136,21 @@ class LimitOffsetTest(fixtures.TablesTest):
[(2, 2, 3), (3, 3, 4)]
)
+ def test_limit_offset_nobinds(self):
+ """test that 'literal binds' mode works - no bound params."""
+
+ table = self.tables.some_table
+ stmt = select([table]).order_by(table.c.id).limit(2).offset(1)
+ sql = stmt.compile(
+ dialect=config.db.dialect,
+ compile_kwargs={"literal_binds": True})
+ sql = str(sql)
+
+ self._assert_result(
+ sql,
+ [(2, 2, 3), (3, 3, 4)]
+ )
+
@testing.requires.bound_limit_offset
def test_bound_limit(self):
table = self.tables.some_table