Blame use-unittest-mock-builtin.patch

8d487a2
From 8459c208f11e64b871ed502c9ce56befa2a2ed97 Mon Sep 17 00:00:00 2001
4d8f763
From: Major Hayden <major@redhat.com>
8d487a2
Date: Fri, 4 Mar 2022 07:02:27 -0600
4d8f763
Subject: [PATCH] Use unittest.mock
4d8f763
4d8f763
---
4d8f763
 tests/asyncio/future/test_async_future.py                   | 2 +-
4d8f763
 tests/asyncio/gapic/test_method_async.py                    | 2 +-
4d8f763
 tests/asyncio/operations_v1/test_operations_async_client.py | 2 +-
4d8f763
 tests/asyncio/test_grpc_helpers_async.py                    | 2 +-
4d8f763
 tests/asyncio/test_operation_async.py                       | 2 +-
4d8f763
 tests/asyncio/test_page_iterator_async.py                   | 2 +-
4d8f763
 tests/asyncio/test_retry_async.py                           | 2 +-
4d8f763
 tests/unit/future/test__helpers.py                          | 2 +-
4d8f763
 tests/unit/future/test_polling.py                           | 2 +-
4d8f763
 tests/unit/gapic/test_method.py                             | 2 +-
4fbeab8
 tests/unit/operations_v1/test_operations_rest_client.py     | 2 +-
4d8f763
 tests/unit/test_bidi.py                                     | 2 +-
4d8f763
 tests/unit/test_exceptions.py                               | 2 +-
8d487a2
 tests/unit/test_extended_operation.py                       | 2 +-
4d8f763
 tests/unit/test_grpc_helpers.py                             | 2 +-
4d8f763
 tests/unit/test_operation.py                                | 2 +-
4d8f763
 tests/unit/test_page_iterator.py                            | 2 +-
4d8f763
 tests/unit/test_path_template.py                            | 2 +-
4d8f763
 tests/unit/test_retry.py                                    | 2 +-
4d8f763
 tests/unit/test_timeout.py                                  | 2 +-
8d487a2
 20 files changed, 20 insertions(+), 20 deletions(-)
4d8f763
4d8f763
diff --git a/tests/asyncio/future/test_async_future.py b/tests/asyncio/future/test_async_future.py
4d8f763
index 1e9ae33..1aaf132 100644
4d8f763
--- a/tests/asyncio/future/test_async_future.py
4d8f763
+++ b/tests/asyncio/future/test_async_future.py
9ca0c3d
@@ -14,7 +14,7 @@
f2d870d
 
8f85f73
 import asyncio
f2d870d
 
8f85f73
-import mock
9ca0c3d
+from unittest import mock
8f85f73
 import pytest
f2d870d
 
8f85f73
 from google.api_core import exceptions
4d8f763
diff --git a/tests/asyncio/gapic/test_method_async.py b/tests/asyncio/gapic/test_method_async.py
4d8f763
index 1410747..7990e46 100644
4d8f763
--- a/tests/asyncio/gapic/test_method_async.py
4d8f763
+++ b/tests/asyncio/gapic/test_method_async.py
4d8f763
@@ -14,7 +14,7 @@
4d8f763
 
8f85f73
 import datetime
f2d870d
 
8f85f73
-import mock
9ca0c3d
+from unittest import mock
8f85f73
 import pytest
f2d870d
 
4d8f763
 try:
4d8f763
diff --git a/tests/asyncio/operations_v1/test_operations_async_client.py b/tests/asyncio/operations_v1/test_operations_async_client.py
4d8f763
index 47c3b4b..67fc941 100644
4d8f763
--- a/tests/asyncio/operations_v1/test_operations_async_client.py
4d8f763
+++ b/tests/asyncio/operations_v1/test_operations_async_client.py
4d8f763
@@ -12,7 +12,7 @@
4d8f763
 # See the License for the specific language governing permissions and
8f85f73
 # limitations under the License.
f2d870d
 
8f85f73
-import mock
9ca0c3d
+from unittest import mock
8f85f73
 import pytest
f2d870d
 
4d8f763
 try:
4d8f763
diff --git a/tests/asyncio/test_grpc_helpers_async.py b/tests/asyncio/test_grpc_helpers_async.py
4d8f763
index 3681a40..cc1a5a4 100644
4d8f763
--- a/tests/asyncio/test_grpc_helpers_async.py
4d8f763
+++ b/tests/asyncio/test_grpc_helpers_async.py
4d8f763
@@ -12,7 +12,7 @@
4d8f763
 # See the License for the specific language governing permissions and
4d8f763
 # limitations under the License.
f2d870d
 
8f85f73
-import mock
9ca0c3d
+from unittest import mock
4d8f763
 import pytest  # noqa: I202
f2d870d
 
4d8f763
 try:
4d8f763
diff --git a/tests/asyncio/test_operation_async.py b/tests/asyncio/test_operation_async.py
4fbeab8
index 26ad7ce..662d956 100644
4d8f763
--- a/tests/asyncio/test_operation_async.py
4d8f763
+++ b/tests/asyncio/test_operation_async.py
9ca0c3d
@@ -13,7 +13,7 @@
8f85f73
 # limitations under the License.
f2d870d
 
f2d870d
 
8f85f73
-import mock
9ca0c3d
+from unittest import mock
8f85f73
 import pytest
f2d870d
 
4d8f763
 try:
4d8f763
diff --git a/tests/asyncio/test_page_iterator_async.py b/tests/asyncio/test_page_iterator_async.py
4d8f763
index 75f9e1c..c3f5d55 100644
4d8f763
--- a/tests/asyncio/test_page_iterator_async.py
4d8f763
+++ b/tests/asyncio/test_page_iterator_async.py
9ca0c3d
@@ -14,7 +14,7 @@
f2d870d
 
8f85f73
 import inspect
f2d870d
 
8f85f73
-import mock
9ca0c3d
+from unittest import mock
8f85f73
 import pytest
f2d870d
 
8f85f73
 from google.api_core import page_iterator_async
4d8f763
diff --git a/tests/asyncio/test_retry_async.py b/tests/asyncio/test_retry_async.py
63dcdc7
index 873caaf..1f57470 100644
4d8f763
--- a/tests/asyncio/test_retry_async.py
4d8f763
+++ b/tests/asyncio/test_retry_async.py
9ca0c3d
@@ -15,7 +15,7 @@
8f85f73
 import datetime
8f85f73
 import re
f2d870d
 
8f85f73
-import mock
9ca0c3d
+from unittest import mock
8f85f73
 import pytest
f2d870d
 
8f85f73
 from google.api_core import exceptions
4d8f763
diff --git a/tests/unit/future/test__helpers.py b/tests/unit/future/test__helpers.py
4d8f763
index 98afc59..a37efdd 100644
4d8f763
--- a/tests/unit/future/test__helpers.py
4d8f763
+++ b/tests/unit/future/test__helpers.py
9ca0c3d
@@ -12,7 +12,7 @@
8f85f73
 # See the License for the specific language governing permissions and
8f85f73
 # limitations under the License.
f2d870d
 
8f85f73
-import mock
9ca0c3d
+from unittest import mock
f2d870d
 
8f85f73
 from google.api_core.future import _helpers
f2d870d
 
4d8f763
diff --git a/tests/unit/future/test_polling.py b/tests/unit/future/test_polling.py
4d8f763
index 2381d03..79f19db 100644
4d8f763
--- a/tests/unit/future/test_polling.py
4d8f763
+++ b/tests/unit/future/test_polling.py
9ca0c3d
@@ -16,7 +16,7 @@ import concurrent.futures
8f85f73
 import threading
8f85f73
 import time
f2d870d
 
8f85f73
-import mock
9ca0c3d
+from unittest import mock
8f85f73
 import pytest
f2d870d
 
8f85f73
 from google.api_core import exceptions, retry
4d8f763
diff --git a/tests/unit/gapic/test_method.py b/tests/unit/gapic/test_method.py
4d8f763
index 9778d23..28323da 100644
4d8f763
--- a/tests/unit/gapic/test_method.py
4d8f763
+++ b/tests/unit/gapic/test_method.py
9ca0c3d
@@ -14,7 +14,7 @@
f2d870d
 
8f85f73
 import datetime
f2d870d
 
8f85f73
-import mock
9ca0c3d
+from unittest import mock
4d8f763
 import pytest
f2d870d
 
4d8f763
 try:
4fbeab8
diff --git a/tests/unit/operations_v1/test_operations_rest_client.py b/tests/unit/operations_v1/test_operations_rest_client.py
4fbeab8
index dddf6b7..f40d780 100644
4fbeab8
--- a/tests/unit/operations_v1/test_operations_rest_client.py
4fbeab8
+++ b/tests/unit/operations_v1/test_operations_rest_client.py
4fbeab8
@@ -15,7 +15,7 @@
4fbeab8
 #
4fbeab8
 import os
4fbeab8
 
4fbeab8
-import mock
4fbeab8
+from unittest import mock
4fbeab8
 import pytest
4fbeab8
 
4fbeab8
 try:
4d8f763
diff --git a/tests/unit/test_bidi.py b/tests/unit/test_bidi.py
4d8f763
index 7fb1620..896f653 100644
4d8f763
--- a/tests/unit/test_bidi.py
4d8f763
+++ b/tests/unit/test_bidi.py
4d8f763
@@ -17,7 +17,7 @@ import logging
4d8f763
 import queue
8f85f73
 import threading
f2d870d
 
8f85f73
-import mock
9ca0c3d
+from unittest import mock
8f85f73
 import pytest
f2d870d
 
4d8f763
 try:
4d8f763
diff --git a/tests/unit/test_exceptions.py b/tests/unit/test_exceptions.py
8d487a2
index 4169ad4..099e423 100644
4d8f763
--- a/tests/unit/test_exceptions.py
4d8f763
+++ b/tests/unit/test_exceptions.py
4d8f763
@@ -15,7 +15,7 @@
4d8f763
 import http.client
8f85f73
 import json
f2d870d
 
8f85f73
-import mock
9ca0c3d
+from unittest import mock
4d8f763
 import pytest
8f85f73
 import requests
f2d870d
 
8d487a2
diff --git a/tests/unit/test_extended_operation.py b/tests/unit/test_extended_operation.py
8d487a2
index 7fcebed..c31640a 100644
8d487a2
--- a/tests/unit/test_extended_operation.py
8d487a2
+++ b/tests/unit/test_extended_operation.py
8d487a2
@@ -16,7 +16,7 @@ import dataclasses
8d487a2
 import enum
8d487a2
 import typing
8d487a2
 
8d487a2
-import mock
8d487a2
+from unittest import mock
8d487a2
 import pytest
8d487a2
 
8d487a2
 from google.api_core import exceptions
4d8f763
diff --git a/tests/unit/test_grpc_helpers.py b/tests/unit/test_grpc_helpers.py
4d8f763
index ca969e4..95b1a24 100644
4d8f763
--- a/tests/unit/test_grpc_helpers.py
4d8f763
+++ b/tests/unit/test_grpc_helpers.py
4d8f763
@@ -12,7 +12,7 @@
4d8f763
 # See the License for the specific language governing permissions and
8f85f73
 # limitations under the License.
f2d870d
 
8f85f73
-import mock
9ca0c3d
+from unittest import mock
8f85f73
 import pytest
f2d870d
 
4d8f763
 try:
4d8f763
diff --git a/tests/unit/test_operation.py b/tests/unit/test_operation.py
4fbeab8
index 22e23bc..8ffee10 100644
4d8f763
--- a/tests/unit/test_operation.py
4d8f763
+++ b/tests/unit/test_operation.py
9ca0c3d
@@ -13,7 +13,7 @@
8f85f73
 # limitations under the License.
f2d870d
 
f2d870d
 
8f85f73
-import mock
9ca0c3d
+from unittest import mock
4d8f763
 import pytest
f2d870d
 
4d8f763
 try:
4d8f763
diff --git a/tests/unit/test_page_iterator.py b/tests/unit/test_page_iterator.py
4d8f763
index a44e998..56be26f 100644
4d8f763
--- a/tests/unit/test_page_iterator.py
4d8f763
+++ b/tests/unit/test_page_iterator.py
9ca0c3d
@@ -15,7 +15,7 @@
8f85f73
 import math
8f85f73
 import types
f2d870d
 
8f85f73
-import mock
9ca0c3d
+from unittest import mock
8f85f73
 import pytest
f2d870d
 
f2d870d
 from google.api_core import page_iterator
4d8f763
diff --git a/tests/unit/test_path_template.py b/tests/unit/test_path_template.py
4d8f763
index 2c5216e..a72f25f 100644
4d8f763
--- a/tests/unit/test_path_template.py
4d8f763
+++ b/tests/unit/test_path_template.py
9ca0c3d
@@ -14,7 +14,7 @@
f2d870d
 
8f85f73
 from __future__ import unicode_literals
f2d870d
 
8f85f73
-import mock
9ca0c3d
+from unittest import mock
8f85f73
 import pytest
f2d870d
 
8f85f73
 from google.api_core import path_template
4d8f763
diff --git a/tests/unit/test_retry.py b/tests/unit/test_retry.py
63dcdc7
index 74c5d77..b7462fb 100644
4d8f763
--- a/tests/unit/test_retry.py
4d8f763
+++ b/tests/unit/test_retry.py
9ca0c3d
@@ -16,7 +16,7 @@ import datetime
8f85f73
 import itertools
8f85f73
 import re
f2d870d
 
8f85f73
-import mock
9ca0c3d
+from unittest import mock
8f85f73
 import pytest
8f85f73
 import requests.exceptions
f2d870d
 
4d8f763
diff --git a/tests/unit/test_timeout.py b/tests/unit/test_timeout.py
4d8f763
index 30d624e..c13e499 100644
4d8f763
--- a/tests/unit/test_timeout.py
4d8f763
+++ b/tests/unit/test_timeout.py
9ca0c3d
@@ -15,7 +15,7 @@
8f85f73
 import datetime
8f85f73
 import itertools
f2d870d
 
8f85f73
-import mock
9ca0c3d
+from unittest import mock
f2d870d
 
8f85f73
 from google.api_core import timeout
f2d870d
 
4d8f763
-- 
8d487a2
2.35.1
4d8f763