Skip to content
This repository was archived by the owner on Sep 5, 2023. It is now read-only.

chore: use gapic-generator-python 1.2.0 #210

Merged
merged 6 commits into from
Aug 17, 2022
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion .github/workflows/unittest.yml
Original file line number Diff line number Diff line change
Expand Up @@ -54,4 +54,4 @@ jobs:
- name: Report coverage results
run: |
coverage combine .coverage-results/.coverage*
coverage report --show-missing --fail-under=99
coverage report --show-missing --fail-under=100
Original file line number Diff line number Diff line change
Expand Up @@ -1234,9 +1234,11 @@ async def set_iam_policy(
optionally specify a ``condition``, which is a logic
expression that further constrains the role binding
based on attributes about the request and/or target
resource. JSON Example.
resource.

.. code-block:: python
**JSON Example**

::

{
"bindings": [
Expand Down Expand Up @@ -1353,9 +1355,11 @@ async def get_iam_policy(
optionally specify a ``condition``, which is a logic
expression that further constrains the role binding
based on attributes about the request and/or target
resource. JSON Example.
resource.

.. code-block:: python
**JSON Example**

::

{
"bindings": [
Expand Down
12 changes: 8 additions & 4 deletions google/cloud/functions_v2/services/function_service/client.py
Original file line number Diff line number Diff line change
Expand Up @@ -1633,9 +1633,11 @@ def set_iam_policy(
optionally specify a ``condition``, which is a logic
expression that further constrains the role binding
based on attributes about the request and/or target
resource. JSON Example.
resource.

.. code-block:: python
**JSON Example**

::

{
"bindings": [
Expand Down Expand Up @@ -1752,9 +1754,11 @@ def get_iam_policy(
optionally specify a ``condition``, which is a logic
expression that further constrains the role binding
based on attributes about the request and/or target
resource. JSON Example.
resource.

.. code-block:: python
**JSON Example**

::

{
"bindings": [
Expand Down
2 changes: 1 addition & 1 deletion noxfile.py
Original file line number Diff line number Diff line change
Expand Up @@ -266,7 +266,7 @@ def cover(session):
test runs (not system test runs), and then erases coverage data.
"""
session.install("coverage", "pytest-cov")
session.run("coverage", "report", "--show-missing", "--fail-under=99")
session.run("coverage", "report", "--show-missing", "--fail-under=100")

session.run("coverage", "erase")

Expand Down
27 changes: 0 additions & 27 deletions owlbot.py
Original file line number Diff line number Diff line change
Expand Up @@ -25,32 +25,6 @@
default_version = "v1"

for library in s.get_staging_dirs(default_version):
# work around issues with docstrings
s.replace(
library / "google/cloud/**/*.py",
"""resource.
\*\*JSON Example\*\*
::""",
"""resource. JSON Example.

.. code-block:: python\n""",
)

s.replace(
library / "google/cloud/**/*.py",
"""\*\*YAML Example\*\*
::""",
"""\n **YAML Example**

::\n""",
)

s.replace(library / "google/cloud/**/*.py",
""" For a description of IAM and its features, see the `IAM
developer's""",
"""\n For a description of IAM and its features, see the `IAM
developer's"""
)
s.move(library, excludes=["setup.py"])

s.remove_staging_dirs()
Expand All @@ -60,7 +34,6 @@
# ----------------------------------------------------------------------------

templated_files = gcp.CommonTemplates().py_library(
cov_level=99,
microgenerator=True,
versions=gcp.common.detect_versions(path="./google", default_first=True),
)
Expand Down
6 changes: 3 additions & 3 deletions tests/unit/gapic/functions_v2/test_function_service.py
Original file line number Diff line number Diff line change
Expand Up @@ -3562,7 +3562,7 @@ def test_get_operation(transport: str = "grpc"):


@pytest.mark.asyncio
async def test_get_operation(transport: str = "grpc"):
async def test_get_operation_async(transport: str = "grpc"):
client = FunctionServiceAsyncClient(
credentials=ga_credentials.AnonymousCredentials(),
transport=transport,
Expand Down Expand Up @@ -3707,7 +3707,7 @@ def test_list_operations(transport: str = "grpc"):


@pytest.mark.asyncio
async def test_list_operations(transport: str = "grpc"):
async def test_list_operations_async(transport: str = "grpc"):
client = FunctionServiceAsyncClient(
credentials=ga_credentials.AnonymousCredentials(),
transport=transport,
Expand Down Expand Up @@ -3852,7 +3852,7 @@ def test_list_locations(transport: str = "grpc"):


@pytest.mark.asyncio
async def test_list_locations(transport: str = "grpc"):
async def test_list_locations_async(transport: str = "grpc"):
client = FunctionServiceAsyncClient(
credentials=ga_credentials.AnonymousCredentials(),
transport=transport,
Expand Down