summaryrefslogtreecommitdiff
path: root/test/sql
diff options
context:
space:
mode:
authorDaniel Lister <dan.lister@gmail.com>2019-01-24 16:35:16 -0500
committerMike Bayer <mike_mp@zzzcomputing.com>2019-01-25 11:19:03 -0500
commit2bbd3ac1fb6049fc7195821798f02ce7fa56a7e9 (patch)
treeba97d2cda12bb1d7994ae7d58b492b6b803db208 /test/sql
parenta11a5f5af6b0c76d6f07a7ed3dd8eff7dda95ed6 (diff)
downloadsqlalchemy-2bbd3ac1fb6049fc7195821798f02ce7fa56a7e9.tar.gz
Add getters for all execution_options
Added accessors for execution options to Core and ORM, via :meth:`.Query.get_execution_options`, :meth:`.Connection.get_execution_options`, :meth:`.Engine.get_execution_options`, and :meth:`.Executable.get_execution_options`. PR courtesy Daniel Lister. Fixes: #4406 Closes: #4465 Pull-request: https://github.com/sqlalchemy/sqlalchemy/pull/4465 Pull-request-sha: 9674688bb5e80471a6a421bac06f995c2e64f8f7 Change-Id: I93ba51d7a2d687e255edd6938db15615e56dd237
Diffstat (limited to 'test/sql')
-rw-r--r--test/sql/test_generative.py6
1 files changed, 3 insertions, 3 deletions
diff --git a/test/sql/test_generative.py b/test/sql/test_generative.py
index f030f1d9c..ccb5b15ea 100644
--- a/test/sql/test_generative.py
+++ b/test/sql/test_generative.py
@@ -1769,10 +1769,10 @@ class SelectTest(fixtures.TestBase, AssertsCompiledSQL):
s2 = s.execution_options(bar="baz")
s3 = s.execution_options(foo="not bar")
# The original select should not be modified.
- assert s._execution_options == dict(foo="bar")
+ eq_(s.get_execution_options(), dict(foo="bar"))
# s2 should have its execution_options based on s, though.
- assert s2._execution_options == dict(foo="bar", bar="baz")
- assert s3._execution_options == dict(foo="not bar")
+ eq_(s2.get_execution_options(), dict(foo="bar", bar="baz"))
+ eq_(s3.get_execution_options(), dict(foo="not bar"))
def test_invalid_options(self):
assert_raises(