From 1328b5e4dc70924d54a7f4c5201a840224252b47 Mon Sep 17 00:00:00 2001 From: Mike Bayer Date: Sun, 16 Mar 2014 21:54:23 -0400 Subject: [PATCH] - use compat version of mock for py3 --- tests/__init__.py | 2 ++ tests/test_op.py | 2 +- 2 files changed, 3 insertions(+), 1 deletion(-) diff --git a/tests/__init__.py b/tests/__init__.py index 9bb5ef6b..cd721ae4 100644 --- a/tests/__init__.py +++ b/tests/__init__.py @@ -29,9 +29,11 @@ testing_config.read(['test.cfg']) if py33: from unittest.mock import Mock, call + from unittest import mock else: try: from mock import Mock, call + import mock except ImportError: raise ImportError( "Alembic's test suite requires the " diff --git a/tests/test_op.py b/tests/test_op.py index 1b82af30..277f1845 100644 --- a/tests/test_op.py +++ b/tests/test_op.py @@ -7,7 +7,7 @@ from sqlalchemy import event from alembic import op from . import op_fixture, assert_raises_message, requires_094, eq_ -import mock +from . import mock @event.listens_for(Table, "after_parent_attach") def _add_cols(table, metadata): -- 2.47.2