From b41c49d15f8174eff494b62389c801bdba0b1a17 Mon Sep 17 00:00:00 2001 From: Daniel Sanche Date: Fri, 2 Sep 2022 12:54:04 -0700 Subject: [PATCH 1/8] chore(tests): update python version used for environment tests --- .kokoro/environment_tests.sh | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/.kokoro/environment_tests.sh b/.kokoro/environment_tests.sh index 2b6fa5177..0ee982290 100755 --- a/.kokoro/environment_tests.sh +++ b/.kokoro/environment_tests.sh @@ -50,11 +50,11 @@ gcloud config set compute/zone us-central1-b gcloud auth configure-docker -q # Remove old nox -python3.6 -m pip uninstall --yes --quiet nox-automation +python3 -m pip uninstall --yes --quiet nox-automation # Install nox -python3.6 -m pip install --upgrade --quiet nox -python3.6 -m nox --version +python3 -m pip install --upgrade --quiet nox +python3 -m nox --version # Install kubectl if [[ "${ENVIRONMENT}" == "kubernetes" ]]; then @@ -73,7 +73,7 @@ echo $ENVCTL_ID # Run the specified environment test set +e -python3.6 -m nox --session "tests(language='python', platform='$ENVIRONMENT')" +python3 -m nox --session "tests(language='python', platform='$ENVIRONMENT')" TEST_STATUS_CODE=$? # destroy resources From c2d681e30e09576e974008e7e931e7d1fbf97d19 Mon Sep 17 00:00:00 2001 From: Daniel Sanche Date: Fri, 2 Sep 2022 14:05:37 -0700 Subject: [PATCH 2/8] changed nox installation method --- .kokoro/environment_tests.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.kokoro/environment_tests.sh b/.kokoro/environment_tests.sh index 0ee982290..959bb6941 100755 --- a/.kokoro/environment_tests.sh +++ b/.kokoro/environment_tests.sh @@ -53,7 +53,7 @@ gcloud auth configure-docker -q python3 -m pip uninstall --yes --quiet nox-automation # Install nox -python3 -m pip install --upgrade --quiet nox +pip3 install --upgrade --quiet nox python3 -m nox --version # Install kubectl From 8cfe2dc66586623dd0c0e23b4cba18640c9304f8 Mon Sep 17 00:00:00 2001 From: Owl Bot Date: Fri, 2 Sep 2022 21:07:16 +0000 Subject: [PATCH 3/8] =?UTF-8?q?=F0=9F=A6=89=20Updates=20from=20OwlBot=20po?= =?UTF-8?q?st-processor?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit See https://github.com/googleapis/repo-automation-bots/blob/main/packages/owl-bot/README.md --- renovate.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/renovate.json b/renovate.json index dde963098..bb005193f 100644 --- a/renovate.json +++ b/renovate.json @@ -5,7 +5,7 @@ ":preserveSemverRanges", ":disableDependencyDashboard" ], - "ignorePaths": [".pre-commit-config.yaml", ".kokoro/requirements.txt", "setup.py"], + "ignorePaths": [".pre-commit-config.yaml", ".kokoro/requirements.txt"], "pip_requirements": { "fileMatch": ["requirements-test.txt", "samples/[\\S/]*constraints.txt", "samples/[\\S/]*constraints-test.txt"] }, From b91df546acf85bf526d0e493cdaa2d76f0e11e38 Mon Sep 17 00:00:00 2001 From: Owl Bot Date: Fri, 2 Sep 2022 21:08:54 +0000 Subject: [PATCH 4/8] =?UTF-8?q?=F0=9F=A6=89=20Updates=20from=20OwlBot=20po?= =?UTF-8?q?st-processor?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit See https://github.com/googleapis/repo-automation-bots/blob/main/packages/owl-bot/README.md --- renovate.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/renovate.json b/renovate.json index bb005193f..dde963098 100644 --- a/renovate.json +++ b/renovate.json @@ -5,7 +5,7 @@ ":preserveSemverRanges", ":disableDependencyDashboard" ], - "ignorePaths": [".pre-commit-config.yaml", ".kokoro/requirements.txt"], + "ignorePaths": [".pre-commit-config.yaml", ".kokoro/requirements.txt", "setup.py"], "pip_requirements": { "fileMatch": ["requirements-test.txt", "samples/[\\S/]*constraints.txt", "samples/[\\S/]*constraints-test.txt"] }, From 33f2f6ae1cc09047ad1b0e9f387ef915130b48b0 Mon Sep 17 00:00:00 2001 From: Daniel Sanche Date: Fri, 2 Sep 2022 15:41:46 -0700 Subject: [PATCH 5/8] install using --user --- .kokoro/environment_tests.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.kokoro/environment_tests.sh b/.kokoro/environment_tests.sh index 959bb6941..e4b0f59df 100755 --- a/.kokoro/environment_tests.sh +++ b/.kokoro/environment_tests.sh @@ -53,7 +53,7 @@ gcloud auth configure-docker -q python3 -m pip uninstall --yes --quiet nox-automation # Install nox -pip3 install --upgrade --quiet nox +python3 -m pip install --upgrade --user --quiet nox python3 -m nox --version # Install kubectl From e5d89286f5de8701847235e00c13322582ea8836 Mon Sep 17 00:00:00 2001 From: Daniel Sanche Date: Fri, 2 Sep 2022 15:45:55 -0700 Subject: [PATCH 6/8] renamed perf test kokoro config --- .kokoro/performance/{presubmit.cfg => performance.cfg} | 0 1 file changed, 0 insertions(+), 0 deletions(-) rename .kokoro/performance/{presubmit.cfg => performance.cfg} (100%) diff --git a/.kokoro/performance/presubmit.cfg b/.kokoro/performance/performance.cfg similarity index 100% rename from .kokoro/performance/presubmit.cfg rename to .kokoro/performance/performance.cfg From e89e62098922f54d5eef195f809744c6ccd93abe Mon Sep 17 00:00:00 2001 From: Daniel Sanche Date: Fri, 2 Sep 2022 15:50:41 -0700 Subject: [PATCH 7/8] install using virtualenv --- .kokoro/environment_tests.sh | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) diff --git a/.kokoro/environment_tests.sh b/.kokoro/environment_tests.sh index e4b0f59df..c80c51d65 100755 --- a/.kokoro/environment_tests.sh +++ b/.kokoro/environment_tests.sh @@ -49,11 +49,10 @@ gcloud config set compute/zone us-central1-b # authenticate docker gcloud auth configure-docker -q -# Remove old nox -python3 -m pip uninstall --yes --quiet nox-automation - # Install nox -python3 -m pip install --upgrade --user --quiet nox +virtualenv .venv +source .venv/bin/activate +python3 -m pip install --upgrade --quiet nox python3 -m nox --version # Install kubectl From 80581b2402e083507a9615aa66e50c05846d5c7a Mon Sep 17 00:00:00 2001 From: Daniel Sanche Date: Fri, 2 Sep 2022 16:17:43 -0700 Subject: [PATCH 8/8] relaxed some performance test limits --- tests/performance/test_performance.py | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/tests/performance/test_performance.py b/tests/performance/test_performance.py index 0f9888f7a..d028a49e8 100644 --- a/tests/performance/test_performance.py +++ b/tests/performance/test_performance.py @@ -196,7 +196,7 @@ def test_client_init_performance(self, time_limit=0.25): total_time = self._print_results(pr, results, time_limit, "Client Init") self.assertLessEqual(total_time, time_limit) - def test_structured_logging_performance(self, time_limit=10): + def test_structured_logging_performance(self, time_limit=12): """ Test the performance of StructuredLoggingHandler @@ -278,7 +278,7 @@ def profiled_code(logger, payload, num_logs=100, flush=False): total_time = self._print_results(pr, results, time_limit, "CloudLoggingHandler") self.assertLessEqual(total_time, time_limit) - def test_logging_performance(self, time_limit=15): + def test_logging_performance(self, time_limit=20): """ Test the performance of logger @@ -312,7 +312,7 @@ def profiled_code(logger, payload, num_logs=100): total_time = self._print_results(pr, results, time_limit, "Logger.Log") self.assertLessEqual(total_time, time_limit) - def test_batch_performance(self, time_limit=10): + def test_batch_performance(self, time_limit=12): """ Test the performance of logger