Skip to content

Commit edd2228

Browse files
chore: use gapic-generator-python 1.0.0 (#250)
- [ ] Regenerate this pull request now. PiperOrigin-RevId: 451250442 Source-Link: googleapis/googleapis@cca5e81 Source-Link: googleapis/googleapis-gen@0b219da Copy-Tag: eyJwIjoiLmdpdGh1Yi8uT3dsQm90LnlhbWwiLCJoIjoiMGIyMTlkYTE2MWE4YmRjYzNjNmY3YjJlZmNkODIxMDUxODJhMzBjYSJ9
1 parent 3c3e3f0 commit edd2228

File tree

12 files changed

+108
-24
lines changed

12 files changed

+108
-24
lines changed

packages/google-cloud-talent/tests/unit/gapic/talent_v4/test_company_service.py

Lines changed: 9 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -13,9 +13,17 @@
1313
# See the License for the specific language governing permissions and
1414
# limitations under the License.
1515
#
16-
import math
1716
import os
1817

18+
# try/except added for compatibility with python < 3.8
19+
try:
20+
from unittest import mock
21+
from unittest.mock import AsyncMock
22+
except ImportError:
23+
import mock
24+
25+
import math
26+
1927
from google.api_core import gapic_v1, grpc_helpers, grpc_helpers_async, path_template
2028
from google.api_core import client_options
2129
from google.api_core import exceptions as core_exceptions
@@ -28,7 +36,6 @@
2836
from google.type import postal_address_pb2 # type: ignore
2937
import grpc
3038
from grpc.experimental import aio
31-
import mock
3239
from proto.marshal.rules.dates import DurationRule, TimestampRule
3340
import pytest
3441

packages/google-cloud-talent/tests/unit/gapic/talent_v4/test_completion.py

Lines changed: 9 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -13,9 +13,17 @@
1313
# See the License for the specific language governing permissions and
1414
# limitations under the License.
1515
#
16-
import math
1716
import os
1817

18+
# try/except added for compatibility with python < 3.8
19+
try:
20+
from unittest import mock
21+
from unittest.mock import AsyncMock
22+
except ImportError:
23+
import mock
24+
25+
import math
26+
1927
from google.api_core import gapic_v1, grpc_helpers, grpc_helpers_async, path_template
2028
from google.api_core import client_options
2129
from google.api_core import exceptions as core_exceptions
@@ -25,7 +33,6 @@
2533
from google.oauth2 import service_account
2634
import grpc
2735
from grpc.experimental import aio
28-
import mock
2936
from proto.marshal.rules.dates import DurationRule, TimestampRule
3037
import pytest
3138

packages/google-cloud-talent/tests/unit/gapic/talent_v4/test_event_service.py

Lines changed: 9 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -13,9 +13,17 @@
1313
# See the License for the specific language governing permissions and
1414
# limitations under the License.
1515
#
16-
import math
1716
import os
1817

18+
# try/except added for compatibility with python < 3.8
19+
try:
20+
from unittest import mock
21+
from unittest.mock import AsyncMock
22+
except ImportError:
23+
import mock
24+
25+
import math
26+
1927
from google.api_core import gapic_v1, grpc_helpers, grpc_helpers_async, path_template
2028
from google.api_core import client_options
2129
from google.api_core import exceptions as core_exceptions
@@ -26,7 +34,6 @@
2634
from google.protobuf import timestamp_pb2 # type: ignore
2735
import grpc
2836
from grpc.experimental import aio
29-
import mock
3037
from proto.marshal.rules.dates import DurationRule, TimestampRule
3138
import pytest
3239

packages/google-cloud-talent/tests/unit/gapic/talent_v4/test_job_service.py

Lines changed: 9 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -13,9 +13,17 @@
1313
# See the License for the specific language governing permissions and
1414
# limitations under the License.
1515
#
16-
import math
1716
import os
1817

18+
# try/except added for compatibility with python < 3.8
19+
try:
20+
from unittest import mock
21+
from unittest.mock import AsyncMock
22+
except ImportError:
23+
import mock
24+
25+
import math
26+
1927
from google.api_core import (
2028
future,
2129
gapic_v1,
@@ -43,7 +51,6 @@
4351
from google.type import timeofday_pb2 # type: ignore
4452
import grpc
4553
from grpc.experimental import aio
46-
import mock
4754
from proto.marshal.rules.dates import DurationRule, TimestampRule
4855
import pytest
4956

packages/google-cloud-talent/tests/unit/gapic/talent_v4/test_tenant_service.py

Lines changed: 9 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -13,9 +13,17 @@
1313
# See the License for the specific language governing permissions and
1414
# limitations under the License.
1515
#
16-
import math
1716
import os
1817

18+
# try/except added for compatibility with python < 3.8
19+
try:
20+
from unittest import mock
21+
from unittest.mock import AsyncMock
22+
except ImportError:
23+
import mock
24+
25+
import math
26+
1927
from google.api_core import gapic_v1, grpc_helpers, grpc_helpers_async, path_template
2028
from google.api_core import client_options
2129
from google.api_core import exceptions as core_exceptions
@@ -26,7 +34,6 @@
2634
from google.protobuf import field_mask_pb2 # type: ignore
2735
import grpc
2836
from grpc.experimental import aio
29-
import mock
3037
from proto.marshal.rules.dates import DurationRule, TimestampRule
3138
import pytest
3239

packages/google-cloud-talent/tests/unit/gapic/talent_v4beta1/test_application_service.py

Lines changed: 9 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -13,9 +13,17 @@
1313
# See the License for the specific language governing permissions and
1414
# limitations under the License.
1515
#
16-
import math
1716
import os
1817

18+
# try/except added for compatibility with python < 3.8
19+
try:
20+
from unittest import mock
21+
from unittest.mock import AsyncMock
22+
except ImportError:
23+
import mock
24+
25+
import math
26+
1927
from google.api_core import gapic_v1, grpc_helpers, grpc_helpers_async, path_template
2028
from google.api_core import client_options
2129
from google.api_core import exceptions as core_exceptions
@@ -29,7 +37,6 @@
2937
from google.type import date_pb2 # type: ignore
3038
import grpc
3139
from grpc.experimental import aio
32-
import mock
3340
from proto.marshal.rules.dates import DurationRule, TimestampRule
3441
import pytest
3542

packages/google-cloud-talent/tests/unit/gapic/talent_v4beta1/test_company_service.py

Lines changed: 9 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -13,9 +13,17 @@
1313
# See the License for the specific language governing permissions and
1414
# limitations under the License.
1515
#
16-
import math
1716
import os
1817

18+
# try/except added for compatibility with python < 3.8
19+
try:
20+
from unittest import mock
21+
from unittest.mock import AsyncMock
22+
except ImportError:
23+
import mock
24+
25+
import math
26+
1927
from google.api_core import gapic_v1, grpc_helpers, grpc_helpers_async, path_template
2028
from google.api_core import client_options
2129
from google.api_core import exceptions as core_exceptions
@@ -28,7 +36,6 @@
2836
from google.type import postal_address_pb2 # type: ignore
2937
import grpc
3038
from grpc.experimental import aio
31-
import mock
3239
from proto.marshal.rules.dates import DurationRule, TimestampRule
3340
import pytest
3441

packages/google-cloud-talent/tests/unit/gapic/talent_v4beta1/test_completion.py

Lines changed: 9 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -13,9 +13,17 @@
1313
# See the License for the specific language governing permissions and
1414
# limitations under the License.
1515
#
16-
import math
1716
import os
1817

18+
# try/except added for compatibility with python < 3.8
19+
try:
20+
from unittest import mock
21+
from unittest.mock import AsyncMock
22+
except ImportError:
23+
import mock
24+
25+
import math
26+
1927
from google.api_core import gapic_v1, grpc_helpers, grpc_helpers_async, path_template
2028
from google.api_core import client_options
2129
from google.api_core import exceptions as core_exceptions
@@ -25,7 +33,6 @@
2533
from google.oauth2 import service_account
2634
import grpc
2735
from grpc.experimental import aio
28-
import mock
2936
from proto.marshal.rules.dates import DurationRule, TimestampRule
3037
import pytest
3138

packages/google-cloud-talent/tests/unit/gapic/talent_v4beta1/test_event_service.py

Lines changed: 9 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -13,9 +13,17 @@
1313
# See the License for the specific language governing permissions and
1414
# limitations under the License.
1515
#
16-
import math
1716
import os
1817

18+
# try/except added for compatibility with python < 3.8
19+
try:
20+
from unittest import mock
21+
from unittest.mock import AsyncMock
22+
except ImportError:
23+
import mock
24+
25+
import math
26+
1927
from google.api_core import gapic_v1, grpc_helpers, grpc_helpers_async, path_template
2028
from google.api_core import client_options
2129
from google.api_core import exceptions as core_exceptions
@@ -26,7 +34,6 @@
2634
from google.protobuf import timestamp_pb2 # type: ignore
2735
import grpc
2836
from grpc.experimental import aio
29-
import mock
3037
from proto.marshal.rules.dates import DurationRule, TimestampRule
3138
import pytest
3239

packages/google-cloud-talent/tests/unit/gapic/talent_v4beta1/test_job_service.py

Lines changed: 9 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -13,9 +13,17 @@
1313
# See the License for the specific language governing permissions and
1414
# limitations under the License.
1515
#
16-
import math
1716
import os
1817

18+
# try/except added for compatibility with python < 3.8
19+
try:
20+
from unittest import mock
21+
from unittest.mock import AsyncMock
22+
except ImportError:
23+
import mock
24+
25+
import math
26+
1927
from google.api_core import (
2028
future,
2129
gapic_v1,
@@ -43,7 +51,6 @@
4351
from google.type import timeofday_pb2 # type: ignore
4452
import grpc
4553
from grpc.experimental import aio
46-
import mock
4754
from proto.marshal.rules.dates import DurationRule, TimestampRule
4855
import pytest
4956

0 commit comments

Comments
 (0)