1
0
mirror of https://github.com/httpie/cli.git synced 2026-04-24 19:53:55 +02:00

Replace usage of mock with unittest.mock (#1054)

Since Python 3, the mock dependency is no more required as
it is already part of the unittest module.
This commit is contained in:
Mickaël Schoentgen
2021-04-30 15:08:27 +02:00
committed by GitHub
parent 611bcdaab1
commit 1274d869f6
9 changed files with 7 additions and 9 deletions
-1
View File
@@ -1,4 +1,3 @@
mock
pytest
pytest-cov
pytest-httpbin>=0.0.6
-1
View File
@@ -34,7 +34,6 @@ class PyTest(TestCommand):
tests_require = [
'pytest-httpbin',
'pytest',
'mock',
]
+1 -1
View File
@@ -1,5 +1,5 @@
"""HTTP authentication-related tests."""
import mock
from unittest import mock
import pytest
from httpie.plugins.builtin import HTTPBasicAuth
+1 -1
View File
@@ -1,4 +1,4 @@
from mock import mock
from unittest import mock
from httpie.cli.constants import SEPARATOR_CREDENTIALS
from httpie.plugins import AuthPlugin
+1 -1
View File
@@ -1,10 +1,10 @@
import os
import tempfile
import time
from unittest import mock
from urllib.request import urlopen
import pytest
import mock
from requests.structures import CaseInsensitiveDict
from httpie.downloads import (
+1 -1
View File
@@ -1,4 +1,4 @@
import mock
from unittest import mock
from pytest import raises
from requests import Request
from requests.exceptions import ConnectionError
+1 -1
View File
@@ -1,4 +1,4 @@
import mock
from unittest import mock
from httpie.status import ExitStatus
from utils import MockEnvironment, http, HTTP_OK
+1 -1
View File
@@ -1,7 +1,7 @@
import argparse
from pathlib import Path
from unittest import mock
import mock
import json
import os
import tempfile
+1 -1
View File
@@ -3,7 +3,7 @@ import json
import os
import shutil
from datetime import datetime
from mock import mock
from unittest import mock
from tempfile import gettempdir
import pytest