Revert the last two mock PRs (#7903)

* Revert "Do not require mock in Python 3 in certbot module (#7895)"

This reverts commit 77871ba71c.

* Revert "Do not require mock in Python 3 in acme module (#7894)"

This reverts commit cd0acf5dcc.
This commit is contained in:
ohemorange
2020-04-13 17:09:24 -07:00
committed by GitHub
parent 77871ba71c
commit ff732bf975
48 changed files with 49 additions and 205 deletions
+1 -4
View File
@@ -4,10 +4,7 @@ import shutil
import unittest
import josepy as jose
try:
import mock
except ImportError: # pragma: no cover
from unittest import mock
import mock
from acme import challenges
from certbot import achallenges
+1 -4
View File
@@ -3,10 +3,7 @@ import functools
import string
import unittest
try:
import mock
except ImportError: # pragma: no cover
from unittest import mock
import mock
import pkg_resources
import six
import zope.interface
@@ -2,10 +2,7 @@
import unittest
try:
import mock
except ImportError: # pragma: no cover
from unittest import mock
import mock
from certbot.plugins import dns_common_lexicon
from certbot.plugins import dns_test_common_lexicon
+1 -4
View File
@@ -4,10 +4,7 @@ import collections
import logging
import unittest
try:
import mock
except ImportError: # pragma: no cover
from unittest import mock
import mock
from certbot import errors
from certbot import util
+1 -4
View File
@@ -1,10 +1,7 @@
"""Tests for new style enhancements"""
import unittest
try:
import mock
except ImportError: # pragma: no cover
from unittest import mock
import mock
from certbot._internal.plugins import null
from certbot.plugins import enhancements
+1 -4
View File
@@ -2,10 +2,7 @@
import sys
import unittest
try:
import mock
except ImportError: # pragma: no cover
from unittest import mock
import mock
import six
from acme import challenges
+1 -4
View File
@@ -1,10 +1,7 @@
"""Tests for certbot._internal.plugins.null."""
import unittest
try:
import mock
except ImportError: # pragma: no cover
from unittest import mock
import mock
import six
+1 -4
View File
@@ -2,10 +2,7 @@
import sys
import unittest
try:
import mock
except ImportError: # pragma: no cover
from unittest import mock
import mock
import zope.component
from certbot import errors
+1 -4
View File
@@ -5,10 +5,7 @@ from socket import errno as socket_errors # type: ignore
import unittest
import josepy as jose
try:
import mock
except ImportError: # pragma: no cover
from unittest import mock
import mock
import OpenSSL.crypto # pylint: disable=unused-import
import six
+1 -4
View File
@@ -2,10 +2,7 @@
import json
import unittest
try:
import mock
except ImportError: # pragma: no cover
from unittest import mock
import mock
from certbot import errors
from certbot.compat import filesystem
+1 -4
View File
@@ -1,10 +1,7 @@
"""Tests for certbot.plugins.util."""
import unittest
try:
import mock
except ImportError: # pragma: no cover
from unittest import mock
import mock
from certbot.compat import os
+1 -4
View File
@@ -10,10 +10,7 @@ import tempfile
import unittest
import josepy as jose
try:
import mock
except ImportError: # pragma: no cover
from unittest import mock
import mock
import six
from acme import challenges