aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorChristopher Allan Webber <cwebber@dustycloud.org>2014-09-16 14:46:02 -0500
committerChristopher Allan Webber <cwebber@dustycloud.org>2014-09-16 14:46:02 -0500
commitfa3f46d7144629eed6f1f6f9abc884a1b8f4c330 (patch)
treed4fc5a3ddd945492b5897fe4cfa774a7da2aba3c
parentb6774d339af5344ead3b1d11b72e365fee01fbb1 (diff)
downloadmediagoblin-fa3f46d7144629eed6f1f6f9abc884a1b8f4c330.tar.lz
mediagoblin-fa3f46d7144629eed6f1f6f9abc884a1b8f4c330.tar.xz
mediagoblin-fa3f46d7144629eed6f1f6f9abc884a1b8f4c330.zip
Import mock correctly on py3
This commit sponsored by Andrew McNicol. Thank you!
-rw-r--r--mediagoblin/tests/test_util.py5
1 files changed, 4 insertions, 1 deletions
diff --git a/mediagoblin/tests/test_util.py b/mediagoblin/tests/test_util.py
index e1c3c7e5..8193233f 100644
--- a/mediagoblin/tests/test_util.py
+++ b/mediagoblin/tests/test_util.py
@@ -14,7 +14,10 @@
# You should have received a copy of the GNU Affero General Public License
# along with this program. If not, see <http://www.gnu.org/licenses/>.
-import mock
+try:
+ import mock
+except ImportError:
+ import unittest.mock as mock
import email
import pytest
import smtplib