diff options
author | mike bayer <mike_mp@zzzcomputing.com> | 2017-07-24 16:54:13 -0400 |
---|---|---|
committer | Gerrit Code Review <gerrit@awstats.zzzcomputing.com> | 2017-07-24 16:54:13 -0400 |
commit | 81f34b2f33b8aa55bc587994125d65244fdf5e52 (patch) | |
tree | 1fd9137b3dd9f8919846379f0c0f142c80fff5f5 | |
parent | fea7c7e48f5ebe141165d4a1230a741fd63478d1 (diff) | |
parent | 7d4005156b5a48989dae7c4424faafc03cc8410d (diff) | |
download | sqlalchemy-81f34b2f33b8aa55bc587994125d65244fdf5e52.tar.gz |
Merge "Ensure we check for boolean condition when we inspect __exit__()"
-rw-r--r-- | doc/build/changelog/unreleased_10/4034.rst | 7 | ||||
-rw-r--r-- | lib/sqlalchemy/testing/util.py | 2 |
2 files changed, 8 insertions, 1 deletions
diff --git a/doc/build/changelog/unreleased_10/4034.rst b/doc/build/changelog/unreleased_10/4034.rst new file mode 100644 index 000000000..ac4f229b0 --- /dev/null +++ b/doc/build/changelog/unreleased_10/4034.rst @@ -0,0 +1,7 @@ +.. change:: + :tags: bug, tests, py3k + :tickets: 4034 + :versions: 1.0.18, 1.1.12, 1.2.0b2 + + Fixed issue in testing fixtures which was incompatible with a change + made as of Python 3.6.2 involving context managers.
\ No newline at end of file diff --git a/lib/sqlalchemy/testing/util.py b/lib/sqlalchemy/testing/util.py index a37637ac0..fe696bcd4 100644 --- a/lib/sqlalchemy/testing/util.py +++ b/lib/sqlalchemy/testing/util.py @@ -161,7 +161,7 @@ def run_as_contextmanager(ctx, fn, *arg, **kw): except: exc_info = sys.exc_info() raise_ = ctx.__exit__(*exc_info) - if raise_ is None: + if not raise_: raise else: return raise_ |