Skip to content

Commit 7b5437d

Browse files
chore(python): fix prerelease session [autoapprove] (#589)
Source-Link: googleapis/synthtool@1b9ad76 Post-Processor: gcr.io/cloud-devrel-public-resources/owlbot-python:latest@sha256:9db98b055a7f8bd82351238ccaacfd3cda58cdf73012ab58b8da146368330021 Co-authored-by: Owl Bot <gcf-owl-bot[bot]@users.noreply.github.com>
1 parent 39a40c8 commit 7b5437d

File tree

2 files changed

+20
-17
lines changed

2 files changed

+20
-17
lines changed

packages/google-cloud-logging/.github/.OwlBot.lock.yaml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -13,5 +13,5 @@
1313
# limitations under the License.
1414
docker:
1515
image: gcr.io/cloud-devrel-public-resources/owlbot-python:latest
16-
digest: sha256:e7bb19d47c13839fe8c147e50e02e8b6cf5da8edd1af8b82208cd6f66cc2829c
17-
# created: 2022-07-05T18:31:20.838186805Z
16+
digest: sha256:9db98b055a7f8bd82351238ccaacfd3cda58cdf73012ab58b8da146368330021
17+
# created: 2022-07-25T16:02:49.174178716Z

packages/google-cloud-logging/noxfile.py

Lines changed: 18 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -342,7 +342,8 @@ def prerelease_deps(session):
342342

343343
# Install all dependencies
344344
session.install("-e", ".[all, tests, tracing]")
345-
session.install(*UNIT_TEST_STANDARD_DEPENDENCIES)
345+
unit_deps_all = UNIT_TEST_STANDARD_DEPENDENCIES + UNIT_TEST_EXTERNAL_DEPENDENCIES
346+
session.install(*unit_deps_all)
346347
system_deps_all = (
347348
SYSTEM_TEST_STANDARD_DEPENDENCIES
348349
+ SYSTEM_TEST_EXTERNAL_DEPENDENCIES
@@ -371,12 +372,6 @@ def prerelease_deps(session):
371372

372373
session.install(*constraints_deps)
373374

374-
if os.path.exists("samples/snippets/requirements.txt"):
375-
session.install("-r", "samples/snippets/requirements.txt")
376-
377-
if os.path.exists("samples/snippets/requirements-test.txt"):
378-
session.install("-r", "samples/snippets/requirements-test.txt")
379-
380375
prerel_deps = [
381376
"protobuf",
382377
# dependency of grpc
@@ -413,11 +408,19 @@ def prerelease_deps(session):
413408
system_test_folder_path = os.path.join("tests", "system")
414409

415410
# Only run system tests if found.
416-
if os.path.exists(system_test_path) or os.path.exists(system_test_folder_path):
417-
session.run("py.test", "tests/system")
418-
419-
snippets_test_path = os.path.join("samples", "snippets")
420-
421-
# Only run samples tests if found.
422-
if os.path.exists(snippets_test_path):
423-
session.run("py.test", "samples/snippets")
411+
if os.path.exists(system_test_path):
412+
session.run(
413+
"py.test",
414+
"--verbose",
415+
f"--junitxml=system_{session.python}_sponge_log.xml",
416+
system_test_path,
417+
*session.posargs,
418+
)
419+
if os.path.exists(system_test_folder_path):
420+
session.run(
421+
"py.test",
422+
"--verbose",
423+
f"--junitxml=system_{session.python}_sponge_log.xml",
424+
system_test_folder_path,
425+
*session.posargs,
426+
)

0 commit comments

Comments
 (0)