Skip to content

Commit

Permalink
chore: use gapic-generator-python 1.2.0 (#13)
Browse files Browse the repository at this point in the history
* chore: use gapic-generator-python 1.2.0

PiperOrigin-RevId: 467286830

Source-Link: googleapis/googleapis@e6e875a

Source-Link: googleapis/googleapis-gen@0295ea1
Copy-Tag: eyJwIjoiLmdpdGh1Yi8uT3dsQm90LnlhbWwiLCJoIjoiMDI5NWVhMTRkOWNkNGQ0N2RkYjIzYjllYmQzOWEzMWUyMDM1ZTI4ZiJ9

* 🦉 Updates from OwlBot post-processor

See https://github.com/googleapis/repo-automation-bots/blob/main/packages/owl-bot/README.md

* remove workarounds in owlbot.py; restore 100% coverge

Co-authored-by: Owl Bot <gcf-owl-bot[bot]@users.noreply.github.com>
Co-authored-by: Anthonios Partheniou <partheniou@google.com>
  • Loading branch information
3 people authored Aug 15, 2022
1 parent ed7cd7e commit 6dcb3ad
Show file tree
Hide file tree
Showing 6 changed files with 24 additions and 42 deletions.
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=98
coverage report --show-missing --fail-under=100
Original file line number Diff line number Diff line change
Expand Up @@ -946,9 +946,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.
**JSON Example**
.. code-block:: python
::
{
"bindings": [
Expand Down Expand Up @@ -1065,9 +1067,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.
**JSON Example**
.. code-block:: python
::
{
"bindings": [
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -1183,9 +1183,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.
**JSON Example**
.. code-block:: python
::
{
"bindings": [
Expand Down Expand Up @@ -1302,9 +1304,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.
**JSON Example**
.. code-block:: python
::
{
"bindings": [
Expand Down
2 changes: 1 addition & 1 deletion packages/google-cloud-beyondcorp-appgateways/noxfile.py
Original file line number Diff line number Diff line change
Expand Up @@ -265,7 +265,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=98")
session.run("coverage", "report", "--show-missing", "--fail-under=100")

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

Expand Down
28 changes: 1 addition & 27 deletions packages/google-cloud-beyondcorp-appgateways/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.replace(library / "google/cloud/**/*.py","\n ------------\n\n ",":")
s.replace(library / "google/cloud/**/*.py","\n ----------\n\n ",":")
s.move(library, excludes=["google/cloud/beyondcorp_appgateways", "setup.py"])
Expand All @@ -61,7 +35,7 @@
# ----------------------------------------------------------------------------

templated_files = gcp.CommonTemplates().py_library(
cov_level=98,
cov_level=100,
microgenerator=True,
versions=gcp.common.detect_versions(path="./google", default_first=True),
)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2650,7 +2650,7 @@ def test_delete_operation(transport: str = "grpc"):


@pytest.mark.asyncio
async def test_delete_operation(transport: str = "grpc"):
async def test_delete_operation_async(transport: str = "grpc"):
client = AppGatewaysServiceAsyncClient(
credentials=ga_credentials.AnonymousCredentials(),
transport=transport,
Expand Down Expand Up @@ -2789,7 +2789,7 @@ def test_cancel_operation(transport: str = "grpc"):


@pytest.mark.asyncio
async def test_cancel_operation(transport: str = "grpc"):
async def test_cancel_operation_async(transport: str = "grpc"):
client = AppGatewaysServiceAsyncClient(
credentials=ga_credentials.AnonymousCredentials(),
transport=transport,
Expand Down Expand Up @@ -2928,7 +2928,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 = AppGatewaysServiceAsyncClient(
credentials=ga_credentials.AnonymousCredentials(),
transport=transport,
Expand Down Expand Up @@ -3073,7 +3073,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 = AppGatewaysServiceAsyncClient(
credentials=ga_credentials.AnonymousCredentials(),
transport=transport,
Expand Down Expand Up @@ -3218,7 +3218,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 = AppGatewaysServiceAsyncClient(
credentials=ga_credentials.AnonymousCredentials(),
transport=transport,
Expand Down

0 comments on commit 6dcb3ad

Please sign in to comment.