From 63a5ddcb6c0040918189db17ee236007dba9f993 Mon Sep 17 00:00:00 2001 From: James Sumners Date: Mon, 15 Apr 2024 13:33:16 -0400 Subject: [PATCH] chore: Updated versioned tests to use quiet output mode (#2145) --- .github/workflows/ci-workflow.yml | 6 ++-- .github/workflows/versioned-coverage.yml | 4 +++ .../workflows/versioned-security-agent.yml | 4 +++ THIRD_PARTY_NOTICES.md | 33 +------------------ bin/run-versioned-tests.sh | 14 +++++--- package-lock.json | 8 ++--- package.json | 2 +- third_party_manifest.json | 25 ++++---------- 8 files changed, 33 insertions(+), 63 deletions(-) diff --git a/.github/workflows/ci-workflow.yml b/.github/workflows/ci-workflow.yml index d70533926d..c42777bada 100644 --- a/.github/workflows/ci-workflow.yml +++ b/.github/workflows/ci-workflow.yml @@ -2,7 +2,9 @@ name: Node Agent CI on: [push, pull_request, workflow_dispatch] - +env: + # Enable versioned runner quiet mode to make CI output easier to read: + OUTPUT_MODE: quiet jobs: skip_if_release: @@ -161,7 +163,7 @@ jobs: with: name: logs-${{ matrix.node-version }}.tgz path: ./logs-${{ matrix.node-version }}.tgz - + # There is no coverage for external as that's tracked in their respective repos versioned-external: needs: skip_if_release diff --git a/.github/workflows/versioned-coverage.yml b/.github/workflows/versioned-coverage.yml index 9b112d871b..6f42a79258 100644 --- a/.github/workflows/versioned-coverage.yml +++ b/.github/workflows/versioned-coverage.yml @@ -7,6 +7,10 @@ on: schedule: - cron: '0 9 * * 1-5' +env: + # Enable versioned runner quiet mode to make CI output easier to read: + OUTPUT_MODE: quiet + jobs: legacy-context: runs-on: ubuntu-latest diff --git a/.github/workflows/versioned-security-agent.yml b/.github/workflows/versioned-security-agent.yml index 25e4d9ab1d..4e09cd4827 100644 --- a/.github/workflows/versioned-security-agent.yml +++ b/.github/workflows/versioned-security-agent.yml @@ -25,6 +25,10 @@ on: branches: - main +env: + # Enable versioned runner quiet mode to make CI output easier to read: + OUTPUT_MODE: quiet + jobs: should_run: # Used to determine if the `@newrelic/security-agent` dependency has diff --git a/THIRD_PARTY_NOTICES.md b/THIRD_PARTY_NOTICES.md index 5ab8d5f1cf..b61a5cd0f1 100644 --- a/THIRD_PARTY_NOTICES.md +++ b/THIRD_PARTY_NOTICES.md @@ -66,7 +66,6 @@ code, the source code can be found at [https://github.com/newrelic/node-newrelic * [rimraf](#rimraf) * [should](#should) * [sinon](#sinon) -* [superagent](#superagent) * [tap](#tap) * [temp](#temp) * [when](#when) @@ -1715,7 +1714,7 @@ This product includes source derived from [@newrelic/newrelic-oss-cli](https://g ### @newrelic/test-utilities -This product includes source derived from [@newrelic/test-utilities](https://github.com/newrelic/node-test-utilities) ([v8.4.0](https://github.com/newrelic/node-test-utilities/tree/v8.4.0)), distributed under the [Apache-2.0 License](https://github.com/newrelic/node-test-utilities/blob/v8.4.0/LICENSE): +This product includes source derived from [@newrelic/test-utilities](https://github.com/newrelic/node-test-utilities) ([v8.5.0](https://github.com/newrelic/node-test-utilities/tree/v8.5.0)), distributed under the [Apache-2.0 License](https://github.com/newrelic/node-test-utilities/blob/v8.5.0/LICENSE): ``` Apache License @@ -3147,36 +3146,6 @@ THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. ``` -### superagent - -This product includes source derived from [superagent](https://github.com/ladjs/superagent) ([v8.1.2](https://github.com/ladjs/superagent/tree/v8.1.2)), distributed under the [MIT License](https://github.com/ladjs/superagent/blob/v8.1.2/LICENSE): - -``` -(The MIT License) - -Copyright (c) 2014-2016 TJ Holowaychuk - -Permission is hereby granted, free of charge, to any person obtaining -a copy of this software and associated documentation files (the -'Software'), to deal in the Software without restriction, including -without limitation the rights to use, copy, modify, merge, publish, -distribute, sublicense, and/or sell copies of the Software, and to -permit persons to whom the Software is furnished to do so, subject to -the following conditions: - -The above copyright notice and this permission notice shall be -included in all copies or substantial portions of the Software. - -THE SOFTWARE IS PROVIDED 'AS IS', WITHOUT WARRANTY OF ANY KIND, -EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF -MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. -IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY -CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, -TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE -SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. - -``` - ### tap This product includes source derived from [tap](https://github.com/tapjs/node-tap) ([v16.3.10](https://github.com/tapjs/node-tap/tree/v16.3.10)), distributed under the [ISC License](https://github.com/tapjs/node-tap/blob/v16.3.10/LICENSE): diff --git a/bin/run-versioned-tests.sh b/bin/run-versioned-tests.sh index ba8cedefe2..9dd000ffb7 100755 --- a/bin/run-versioned-tests.sh +++ b/bin/run-versioned-tests.sh @@ -15,11 +15,15 @@ SKIP_C8="${SKIP_C8:-false}" # HTML reports too C8_REPORTER="${C8_REPORTER:-lcov}" # Options: none, only, include -# None skips running external +# None skips running external # Only runs only external -# Inclue runs external with "internal" +# Include runs external with "internal" EXTERNAL_MODE="${EXTERNAL_MODE:-include}" +# OUTPUT_MODE maps to `--print` of the versioned-tests runner. +# Known values are "simple", "pretty", and "quiet". +OUTPUT_MODE="${OUTPUT_MODE:-pretty}" + # Determine context manager for sanity sake if [[ $NEW_RELIC_FEATURE_FLAG_LEGACY_CONTEXT_MANAGER == 1 ]]; then @@ -40,7 +44,7 @@ then "test/versioned-external/TEMP_TESTS/${1}/tests/versioned" ) elif [[ "$EXTERNAL_MODE" = "none" ]]; - then + then directories=( "test/versioned/${1}" ) @@ -59,7 +63,7 @@ else "test/versioned-external" ) elif [[ "$EXTERNAL_MODE" = "none" ]]; - then + then directories=( "test/versioned/" ) @@ -96,4 +100,4 @@ then fi export NR_LOADER=./esm-loader.mjs -time $C8 ./node_modules/.bin/versioned-tests $VERSIONED_MODE -i 2 --all --strict --samples $SAMPLES $JOBS_ARGS ${directories[@]} +time $C8 ./node_modules/.bin/versioned-tests $VERSIONED_MODE --print $OUTPUT_MODE -i 2 --all --strict --samples $SAMPLES $JOBS_ARGS ${directories[@]} diff --git a/package-lock.json b/package-lock.json index 4c25e9f47f..97bf2b0f9f 100644 --- a/package-lock.json +++ b/package-lock.json @@ -32,7 +32,7 @@ "devDependencies": { "@newrelic/eslint-config": "^0.3.0", "@newrelic/newrelic-oss-cli": "^0.1.2", - "@newrelic/test-utilities": "^8.4.0", + "@newrelic/test-utilities": "^8.5.0", "@octokit/rest": "^18.0.15", "@slack/bolt": "^3.7.0", "ajv": "^6.12.6", @@ -989,9 +989,9 @@ } }, "node_modules/@newrelic/test-utilities": { - "version": "8.4.0", - "resolved": "https://registry.npmjs.org/@newrelic/test-utilities/-/test-utilities-8.4.0.tgz", - "integrity": "sha512-WCr/zGAwZs2B1mI/Kf0aR+XofM61Vb0pPjCyS7adyLFBd82Ccb0kPRGiycc07ITQKvtmd6LdQnl3a2K+qaKA5g==", + "version": "8.5.0", + "resolved": "https://registry.npmjs.org/@newrelic/test-utilities/-/test-utilities-8.5.0.tgz", + "integrity": "sha512-lrdcoJiolBRhhuT7cd0YUN23zsF2WX0kUfmfA8+IGU+9T0witbkLC4AUnaaM9/OQx5qyZveaw5TFQl3XUSHTBg==", "dev": true, "dependencies": { "@smithy/eventstream-codec": "^2.1.1", diff --git a/package.json b/package.json index 89be12d50d..42b9ab6ce6 100644 --- a/package.json +++ b/package.json @@ -216,7 +216,7 @@ "devDependencies": { "@newrelic/eslint-config": "^0.3.0", "@newrelic/newrelic-oss-cli": "^0.1.2", - "@newrelic/test-utilities": "^8.4.0", + "@newrelic/test-utilities": "^8.5.0", "@octokit/rest": "^18.0.15", "@slack/bolt": "^3.7.0", "ajv": "^6.12.6", diff --git a/third_party_manifest.json b/third_party_manifest.json index 222d2d6e16..3b922b6895 100644 --- a/third_party_manifest.json +++ b/third_party_manifest.json @@ -1,5 +1,5 @@ { - "lastUpdated": "Mon Apr 15 2024 07:50:25 GMT-0400 (Eastern Daylight Time)", + "lastUpdated": "Mon Apr 15 2024 12:30:33 GMT-0400 (Eastern Daylight Time)", "projectName": "New Relic Node Agent", "projectUrl": "https://github.com/newrelic/node-newrelic", "includeOptDeps": true, @@ -277,15 +277,15 @@ "licenseTextSource": "file", "publisher": "New Relic" }, - "@newrelic/test-utilities@8.4.0": { + "@newrelic/test-utilities@8.5.0": { "name": "@newrelic/test-utilities", - "version": "8.4.0", - "range": "^8.4.0", + "version": "8.5.0", + "range": "^8.5.0", "licenses": "Apache-2.0", "repoUrl": "https://github.com/newrelic/node-test-utilities", - "versionedRepoUrl": "https://github.com/newrelic/node-test-utilities/tree/v8.4.0", + "versionedRepoUrl": "https://github.com/newrelic/node-test-utilities/tree/v8.5.0", "licenseFile": "node_modules/@newrelic/test-utilities/LICENSE", - "licenseUrl": "https://github.com/newrelic/node-test-utilities/blob/v8.4.0/LICENSE", + "licenseUrl": "https://github.com/newrelic/node-test-utilities/blob/v8.5.0/LICENSE", "licenseTextSource": "file", "publisher": "New Relic Node.js agent team", "email": "nodejs@newrelic.com" @@ -675,19 +675,6 @@ "licenseTextSource": "file", "publisher": "Christian Johansen" }, - "superagent@8.1.2": { - "name": "superagent", - "version": "8.1.2", - "range": "^8.1.2", - "licenses": "MIT", - "repoUrl": "https://github.com/ladjs/superagent", - "versionedRepoUrl": "https://github.com/ladjs/superagent/tree/v8.1.2", - "licenseFile": "node_modules/superagent/LICENSE", - "licenseUrl": "https://github.com/ladjs/superagent/blob/v8.1.2/LICENSE", - "licenseTextSource": "file", - "publisher": "TJ Holowaychuk", - "email": "tj@vision-media.ca" - }, "tap@16.3.10": { "name": "tap", "version": "16.3.10",