Skip to content

test(guardrails): remove redundant runtime-check unit test#9098

Merged
pabloerhard merged 1 commit into
masterfrom
rochdev/remove-redundant-guardrails-unit-test
Jun 26, 2026
Merged

test(guardrails): remove redundant runtime-check unit test#9098
pabloerhard merged 1 commit into
masterfrom
rochdev/remove-redundant-guardrails-unit-test

Conversation

@rochdev

@rochdev rochdev commented Jun 26, 2026

Copy link
Copy Markdown
Member

What

Removes packages/dd-trace/test/guardrails/index.spec.js.

Why

This unit test duplicated existing — and stronger — integration coverage, and was added only to satisfy a Codecov patch-coverage flag.

The behavior is already covered by integration-tests/init.spec.js. Its context('when node version is too recent') block sets pkg.nodeMaxMajor = NODE_MAJOR and asserts the tracer does not initialize, plus the abort telemetry, the incompatible_runtime debug log output, and the DD_INJECT_FORCE override — everything the unit test stubbed to no-ops and more.

The unit test only existed for a coverage metric. #9033 refactored the bailout block in guardrails/index.js, adding new lines. Codecov flagged those new lines as uncovered patch coverage, because the only thing exercising that block — the integration test above — runs in a sandbox and doesn't count toward nyc. The unit test was added to clear that flag. AGENTS.md explicitly discourages this ("Don't add redundant unit tests solely to improve coverage numbers").

It was also fragile. It relied on proxyquire intercepting an in-function require('../../../../package.json'), which is environment-dependent. It failed on the v5.110.0 release proposal on Node 26 — yet Platform / integration (node-latest) (which runs init.spec.js on Node 26) passed on that same run, proving the real bailout path is correct and the failure was a mocking artifact, not a bug.

Coverage note

.codecov.yml has project: off and patch only measures added lines on PRs, so this pure deletion does not trip a Codecov gate. The bailout lines remain covered by init.spec.js (just not nyc-visible). If a future change to the bailout block re-triggers a patch-coverage flag, the right fix is to make integration coverage count or to exclude the block in .codecov.yml — not to re-add a proxyquire unit test.

The unit-guardrails job still runs telemetry.spec.js, so the mocha glob remains non-empty (verified locally: 9 passing).

🤖 Generated with Claude Code

packages/dd-trace/test/guardrails/index.spec.js duplicated existing
integration coverage. init.spec.js's "when node version is too recent"
context already exercises the incompatible-runtime bailout — plus the
telemetry, debug logs, and DD_INJECT_FORCE override that the unit test
stubbed to no-ops — by setting pkg.nodeMaxMajor = NODE_MAJOR.

The unit test was added in #9033 only to satisfy a Codecov patch-coverage
flag on lines that PR added to the bailout block (integration tests run
in sandboxes and don't count toward nyc). It relied on proxyquire
intercepting an in-function require() of package.json, which is
environment-dependent: it failed on the v5.110.0 release proposal on
Node 26 even though the real bailout — verified by the passing
init.spec.js integration test on that same run — works correctly.

Co-Authored-By: Claude Opus 4.8 (1M context) <[email protected]>
@dd-octo-sts

dd-octo-sts Bot commented Jun 26, 2026

Copy link
Copy Markdown
Contributor

Overall package size

Self size: 6.37 MB
Deduped: 7.43 MB
No deduping: 7.43 MB

Dependency sizes | name | version | self size | total size | |------|---------|-----------|------------| | import-in-the-middle | 3.2.0 | 104.26 kB | 843.44 kB | | opentracing | 0.14.7 | 194.81 kB | 194.81 kB | | dc-polyfill | 0.1.11 | 25.74 kB | 25.74 kB |

🤖 This report was automatically generated by heaviest-objects-in-the-universe

@datadog-datadog-prod-us1

datadog-datadog-prod-us1 Bot commented Jun 26, 2026

Copy link
Copy Markdown

Tests

🎉 All green!

🧪 All tests passed
❄️ No new flaky tests detected

This comment will be updated automatically if new data arrives.
🔗 Commit SHA: a85442e | Docs | Datadog PR Page | Give us feedback!

@rochdev
rochdev marked this pull request as ready for review June 26, 2026 19:17
@rochdev
rochdev requested a review from a team as a code owner June 26, 2026 19:17
@pr-commenter

pr-commenter Bot commented Jun 26, 2026

Copy link
Copy Markdown

Benchmarks

Benchmark execution time: 2026-06-26 19:22:04

Comparing candidate commit a85442e in PR branch rochdev/remove-redundant-guardrails-unit-test with baseline commit ece16d5 in branch master.

📊 Benchmarking dashboard

Found 0 performance improvements and 0 performance regressions! Performance is the same for 2253 metrics, 33 unstable metrics.

Explanation

This is an A/B test comparing a candidate commit's performance against that of a baseline commit. Performance changes are noted in the tables below as:

  • 🟩 = significantly better candidate vs. baseline
  • 🟥 = significantly worse candidate vs. baseline

We compute a confidence interval (CI) over the relative difference of means between metrics from the candidate and baseline commits, considering the baseline as the reference.

If the CI is entirely outside the configured SIGNIFICANT_IMPACT_THRESHOLD (or the deprecated UNCONFIDENCE_THRESHOLD), the change is considered significant.

Feel free to reach out to #apm-benchmarking-platform on Slack if you have any questions.

More details about the CI and significant changes

You can imagine this CI as a range of values that is likely to contain the true difference of means between the candidate and baseline commits.

CIs of the difference of means are often centered around 0%, because often changes are not that big:

---------------------------------(------|---^--------)-------------------------------->
                              -0.6%    0%  0.3%     +1.2%
                                 |          |        |
         lower bound of the CI --'          |        |
sample mean (center of the CI) -------------'        |
         upper bound of the CI ----------------------'

As described above, a change is considered significant if the CI is entirely outside the configured SIGNIFICANT_IMPACT_THRESHOLD (or the deprecated UNCONFIDENCE_THRESHOLD).

For instance, for an execution time metric, this confidence interval indicates a significantly worse performance:

----------------------------------------|---------|---(---------^---------)---------->
                                       0%        1%  1.3%      2.2%      3.1%
                                                  |   |         |         |
       significant impact threshold --------------'   |         |         |
                      lower bound of CI --------------'         |         |
       sample mean (center of the CI) --------------------------'         |
                      upper bound of CI ----------------------------------'

Unstable benchmarks

These benchmarks have a confidence interval too wide to call a change; treat them as noise rather than signal.

scenario:appsec-appsec-enabled-24

  • unstable execution_time [-184.380ms; +179.895ms] or [-7.021%; +6.850%]

scenario:appsec-appsec-enabled-26

  • unstable execution_time [-208593.686µs; +207869.352µs] or [-8.322%; +8.293%]

scenario:appsec-appsec-enabled-with-attacks-26

  • unstable execution_time [-127.125ms; +178.666ms] or [-4.459%; +6.267%]

scenario:appsec-control-20

  • unstable execution_time [-152.548ms; +162.745ms] or [-8.713%; +9.295%]

scenario:appsec-control-24

  • unstable execution_time [-104.978ms; +107.768ms] or [-8.653%; +8.883%]

scenario:appsec-control-26

  • unstable execution_time [-119.300ms; +100.574ms] or [-9.954%; +8.392%]

scenario:debugger-line-probe-with-snapshot-default-26

  • unstable cpu_user_time [-1795.936ms; +632.250ms] or [-19.199%; +6.759%]
  • unstable execution_time [-1812.850ms; +651.989ms] or [-18.035%; +6.486%]
  • unstable instructions [-15.9G instructions; +5.6G instructions] or [-20.479%; +7.226%]
  • unstable throughput [-151.779op/s; +388.641op/s] or [-4.643%; +11.890%]

scenario:debugger-line-probe-with-snapshot-minimal-24

  • unstable cpu_user_time [-1840.521ms; +2961.567ms] or [-23.379%; +37.618%]
  • unstable execution_time [-1883.716ms; +2984.548ms] or [-22.037%; +34.915%]
  • unstable instructions [-15.8G instructions; +25.2G instructions] or [-24.586%; +39.274%]
  • unstable max_rss_usage [-7.188MB; +11.131MB] or [-4.545%; +7.037%]
  • unstable throughput [-891.489op/s; +565.307op/s] or [-23.098%; +14.647%]

scenario:debugger-line-probe-without-snapshot-24

  • unstable cpu_user_time [-2695.929ms; +3788.953ms] or [-29.803%; +41.886%]
  • unstable execution_time [-2745.332ms; +3850.336ms] or [-28.192%; +39.539%]
  • unstable instructions [-22.8G instructions; +32.4G instructions] or [-30.743%; +43.668%]
  • unstable max_rss_usage [-9.869MB; +13.821MB] or [-6.081%; +8.516%]
  • unstable throughput [-1128.204op/s; +808.570op/s] or [-32.083%; +22.994%]

scenario:debugger-line-probe-without-snapshot-26

  • unstable cpu_user_time [-1819.248ms; +617.594ms] or [-19.496%; +6.619%]
  • unstable execution_time [-1847.287ms; +615.709ms] or [-18.398%; +6.132%]
  • unstable instructions [-16.4G instructions; +5.5G instructions] or [-21.175%; +7.081%]
  • unstable throughput [-144.328op/s; +412.633op/s] or [-4.410%; +12.608%]

scenario:dogstatsd-with-tags-20

  • unstable cpu_user_time [-470.494ms; +226.005ms] or [-9.367%; +4.500%]
  • unstable execution_time [-470.069ms; +226.603ms] or [-9.226%; +4.447%]
  • unstable throughput [-76416.740op/s; +160448.643op/s] or [-4.641%; +9.745%]

scenario:plugin-graphql-long-with-depth-and-collapse-off-24

  • unstable cpu_user_time [-239.042ms; +353.238ms] or [-5.240%; +7.743%]
  • unstable execution_time [-250.121ms; +375.253ms] or [-5.161%; +7.743%]
  • unstable max_rss_usage [-36.226MB; +47.031MB] or [-6.648%; +8.631%]
  • unstable throughput [-3.629op/s; +2.312op/s] or [-8.208%; +5.228%]

scenario:plugin-graphql-long-with-depth-off-20

  • unstable max_rss_usage [-7.116MB; +16.675MB] or [-4.877%; +11.427%]

scenario:test-optimization-large-suite-20

  • unstable max_rss_usage [-3907.993KB; +4297.660KB] or [-4.926%; +5.417%]

@pabloerhard
pabloerhard merged commit 7756b94 into master Jun 26, 2026
841 of 842 checks passed
@pabloerhard
pabloerhard deleted the rochdev/remove-redundant-guardrails-unit-test branch June 26, 2026 19:26
@codecov

codecov Bot commented Jun 26, 2026

Copy link
Copy Markdown

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 69.58%. Comparing base (ece16d5) to head (a85442e).
⚠️ Report is 2 commits behind head on master.

Additional details and impacted files
@@             Coverage Diff             @@
##           master    #9098       +/-   ##
===========================================
- Coverage   92.82%   69.58%   -23.25%     
===========================================
  Files         889      510      -379     
  Lines       50858    31363    -19495     
  Branches    10016     5525     -4491     
===========================================
- Hits        47209    21823    -25386     
- Misses       3649     9540     +5891     
Flag Coverage Δ
aiguard-integration-latest ?
aiguard-integration-maintenance ?
aiguard-macos ?
aiguard-ubuntu ?
aiguard-windows ?
apm-capabilities-tracing-macos ?
apm-capabilities-tracing-ubuntu-active ?
apm-capabilities-tracing-ubuntu-latest ?
apm-capabilities-tracing-ubuntu-maintenance ?
apm-capabilities-tracing-ubuntu-oldest ?
apm-capabilities-tracing-windows ?
apm-integrations-aerospike-18-gte.5.2.0 ?
apm-integrations-aerospike-20-gte.5.5.0 ?
apm-integrations-aerospike-22-gte.5.12.1 ?
apm-integrations-aerospike-eol- ?
apm-integrations-child-process ?
apm-integrations-confluentinc-kafka-javascript-18 ?
apm-integrations-confluentinc-kafka-javascript-20 ?
apm-integrations-confluentinc-kafka-javascript-22 ?
apm-integrations-confluentinc-kafka-javascript-24 ?
apm-integrations-couchbase-eol ?
apm-integrations-couchbase-oldest ?
apm-integrations-dns ?
apm-integrations-elasticsearch ?
apm-integrations-http-latest ?
apm-integrations-http-maintenance ?
apm-integrations-http-oldest ?
apm-integrations-http2 ?
apm-integrations-kafkajs-latest ?
apm-integrations-kafkajs-oldest ?
apm-integrations-net ?
apm-integrations-next-11.1.4 ?
apm-integrations-next-12.3.7 ?
apm-integrations-next-13.0.0 ?
apm-integrations-next-13.2.0 ?
apm-integrations-next-13.5.11 ?
apm-integrations-next-14.0.0 ?
apm-integrations-next-14.2.35 ?
apm-integrations-next-14.2.6 ?
apm-integrations-next-14.2.7 ?
apm-integrations-next-15.0.0 ?
apm-integrations-next-15.4.0 ?
apm-integrations-next-latest ?
apm-integrations-oracledb ?
apm-integrations-prisma-latest-all ?
apm-integrations-restify ?
apm-integrations-sharedb ?
appsec-express ?
appsec-fastify ?
appsec-graphql ?
appsec-integration-active ?
appsec-integration-latest ?
appsec-integration-maintenance ?
appsec-integration-oldest ?
appsec-kafka ?
appsec-lodash ?
appsec-mongodb-core ?
appsec-mongoose ?
appsec-mysql ?
appsec-next-latest-11.1.4 ?
appsec-next-latest-12.3.7 ?
appsec-next-latest-13.0.0 ?
appsec-next-latest-13.2.0 ?
appsec-next-latest-13.5.11 ?
appsec-next-latest-14.2.35 ?
appsec-next-latest-14.2.6 ?
appsec-next-latest-14.2.7 ?
appsec-next-latest-15.0.0 ?
appsec-next-latest-latest ?
appsec-next-oldest-11.1.4 ?
appsec-next-oldest-12.3.7 ?
appsec-next-oldest-13.0.0 ?
appsec-next-oldest-13.2.0 ?
appsec-next-oldest-13.5.11 ?
appsec-next-oldest-14.0.0 ?
appsec-next-oldest-14.2.35 ?
appsec-next-oldest-14.2.6 ?
appsec-next-oldest-14.2.7 ?
appsec-next-oldest-15.0.0 ?
appsec-next-oldest-latest ?
appsec-node-serialize ?
appsec-passport ?
appsec-postgres ?
appsec-sourcing ?
appsec-stripe ?
appsec-template ?
appsec-ubuntu 57.18% <ø> (-0.06%) ⬇️
appsec-windows 57.01% <ø> (-0.04%) ⬇️
debugger-ubuntu-active ?
debugger-ubuntu-latest ?
debugger-ubuntu-maintenance ?
debugger-ubuntu-oldest 44.29% <ø> (ø)
instrumentations-instrumentation-ai ?
instrumentations-instrumentation-aws-sdk ?
instrumentations-instrumentation-bluebird ?
instrumentations-instrumentation-body-parser ?
instrumentations-instrumentation-child_process ?
instrumentations-instrumentation-connect ?
instrumentations-instrumentation-cookie-parser ?
instrumentations-instrumentation-couchbase-18 ?
instrumentations-instrumentation-couchbase-eol ?
instrumentations-instrumentation-crypto ?
instrumentations-instrumentation-express ?
instrumentations-instrumentation-express-mongo-sanitize ?
instrumentations-instrumentation-express-multi-version ?
instrumentations-instrumentation-express-session ?
instrumentations-instrumentation-fastify ?
instrumentations-instrumentation-fetch ?
instrumentations-instrumentation-fs ?
instrumentations-instrumentation-generic-pool ?
instrumentations-instrumentation-hono ?
instrumentations-instrumentation-http ?
instrumentations-instrumentation-http-client-options ?
instrumentations-instrumentation-kafkajs ?
instrumentations-instrumentation-koa ?
instrumentations-instrumentation-light-my-request ?
instrumentations-instrumentation-mongoose ?
instrumentations-instrumentation-multer ?
instrumentations-instrumentation-mysql2 ?
instrumentations-instrumentation-openai-lifecycle ?
instrumentations-instrumentation-otel-sdk-trace ?
instrumentations-instrumentation-passport ?
instrumentations-instrumentation-passport-http ?
instrumentations-instrumentation-passport-local ?
instrumentations-instrumentation-pg ?
instrumentations-instrumentation-promise ?
instrumentations-instrumentation-promise-js ?
instrumentations-instrumentation-q ?
instrumentations-instrumentation-restify ?
instrumentations-instrumentation-router ?
instrumentations-instrumentation-stripe ?
instrumentations-instrumentation-url ?
instrumentations-instrumentation-when ?
instrumentations-instrumentation-zlib ?
instrumentations-integration-esbuild-0.16.12-active ?
instrumentations-integration-esbuild-0.16.12-latest ?
instrumentations-integration-esbuild-0.16.12-maintenance ?
instrumentations-integration-esbuild-0.16.12-oldest ?
instrumentations-integration-esbuild-latest-active ?
instrumentations-integration-esbuild-latest-latest ?
instrumentations-integration-esbuild-latest-maintenance ?
instrumentations-integration-esbuild-latest-oldest ?
llmobs-ai ?
llmobs-anthropic ?
llmobs-bedrock ?
llmobs-langchain ?
llmobs-openai-latest ?
llmobs-openai-oldest ?
llmobs-sdk-active ?
llmobs-sdk-latest ?
llmobs-sdk-maintenance ?
llmobs-sdk-oldest ?
llmobs-vertex-ai ?
master-coverage 69.58% <ø> (?)
openfeature-macos ?
openfeature-ubuntu ?
openfeature-unit-active ?
openfeature-unit-latest ?
openfeature-unit-maintenance ?
openfeature-unit-oldest ?
openfeature-windows ?
platform-core ?
platform-esbuild ?
platform-instrumentations-misc ?
platform-integration-active ?
platform-integration-latest ?
platform-integration-maintenance ?
platform-integration-oldest ?
platform-shimmer ?
platform-unit-guardrails ?
platform-webpack ?
plugins-aws-durable-execution-sdk-js ?
plugins-axios ?
plugins-azure-cosmos ?
plugins-body-parser ?
plugins-bullmq ?
plugins-cassandra ?
plugins-cookie ?
plugins-cookie-parser ?
plugins-crypto ?
plugins-dd-trace-api ?
plugins-express-mongo-sanitize ?
plugins-express-session ?
plugins-fastify ?
plugins-fetch ?
plugins-fs ?
plugins-generic-pool ?
plugins-google-cloud-pubsub ?
plugins-grpc ?
plugins-handlebars ?
plugins-hapi ?
plugins-hono ?
plugins-ioredis ?
plugins-jest ?
plugins-knex 40.09% <ø> (ø)
plugins-langgraph ?
plugins-ldapjs ?
plugins-light-my-request ?
plugins-limitd-client ?
plugins-lodash ?
plugins-mariadb ?
plugins-memcached ?
plugins-microgateway-core ?
plugins-modelcontextprotocol-sdk ?
plugins-moleculer ?
plugins-mongodb ?
plugins-mongodb-core ?
plugins-mongoose ?
plugins-multer ?
plugins-mysql ?
plugins-mysql2 ?
plugins-nats ?
plugins-node-serialize ?
plugins-opensearch ?
plugins-passport-http ?
plugins-pino ?
plugins-postgres ?
plugins-process ?
plugins-pug ?
plugins-redis ?
plugins-router ?
plugins-sequelize ?
plugins-test-and-upstream-amqp10 ?
plugins-test-and-upstream-amqplib ?
plugins-test-and-upstream-apollo ?
plugins-test-and-upstream-avsc ?
plugins-test-and-upstream-bunyan ?
plugins-test-and-upstream-connect ?
plugins-test-and-upstream-graphql ?
plugins-test-and-upstream-koa ?
plugins-test-and-upstream-protobufjs ?
plugins-test-and-upstream-rhea ?
plugins-undici ?
plugins-url ?
plugins-vm ?
plugins-winston ?
plugins-ws ?
profiling-ubuntu 43.46% <ø> (-0.07%) ⬇️
profiling-windows ?
serverless-aws-sdk-latest-aws-sdk ?
serverless-aws-sdk-latest-bedrockruntime ?
serverless-aws-sdk-latest-client ?
serverless-aws-sdk-latest-dynamodb ?
serverless-aws-sdk-latest-eventbridge ?
serverless-aws-sdk-latest-kinesis ?
serverless-aws-sdk-latest-lambda ?
serverless-aws-sdk-latest-s3 ?
serverless-aws-sdk-latest-serverless-peer-service ?
serverless-aws-sdk-latest-sns ?
serverless-aws-sdk-latest-sqs ?
serverless-aws-sdk-latest-stepfunctions ?
serverless-aws-sdk-latest-util ?
serverless-aws-sdk-oldest-aws-sdk ?
serverless-aws-sdk-oldest-bedrockruntime ?
serverless-aws-sdk-oldest-client ?
serverless-aws-sdk-oldest-dynamodb ?
serverless-aws-sdk-oldest-eventbridge ?
serverless-aws-sdk-oldest-lambda ?
serverless-aws-sdk-oldest-s3 ?
serverless-aws-sdk-oldest-serverless-peer-service ?
serverless-aws-sdk-oldest-sns 38.17% <ø> (-0.07%) ⬇️
serverless-aws-sdk-oldest-sqs ?
serverless-aws-sdk-oldest-stepfunctions ?
serverless-aws-sdk-oldest-util ?
serverless-azure-functions-eventhubs ?
serverless-azure-functions-servicebus ?
serverless-lambda ?
test-optimization-cucumber-latest-7.0.0 ?
test-optimization-cucumber-latest-latest ?
test-optimization-cucumber-oldest-7.0.0 ?
test-optimization-cypress-latest-12.0.0-commonJS ?
test-optimization-cypress-latest-12.0.0-esm ?
test-optimization-cypress-latest-14.5.4-commonJS ?
test-optimization-cypress-latest-14.5.4-esm ?
test-optimization-cypress-latest-latest-commonJS ?
test-optimization-cypress-latest-latest-esm ?
test-optimization-cypress-oldest-12.0.0-commonJS ?
test-optimization-cypress-oldest-12.0.0-esm ?
test-optimization-cypress-oldest-14.5.4-commonJS ?
test-optimization-cypress-oldest-14.5.4-esm ?
test-optimization-jest-latest-latest ?
test-optimization-jest-latest-oldest ?
test-optimization-jest-oldest-latest ?
test-optimization-jest-oldest-oldest 48.96% <ø> (-2.86%) ⬇️
test-optimization-mocha-latest-latest ?
test-optimization-mocha-latest-oldest ?
test-optimization-mocha-oldest-latest ?
test-optimization-mocha-oldest-oldest ?
test-optimization-playwright-latest-latest-playwright-active-test-span ?
test-optimization-playwright-latest-latest-playwright-atr ?
test-optimization-playwright-latest-latest-playwright-impacted-tests ?
test-optimization-playwright-latest-latest-playwright-reporting ?
test-optimization-playwright-latest-latest-playwright-test-management ?
test-optimization-playwright-latest-oldest-playwright-active-test-span ?
test-optimization-playwright-latest-oldest-playwright-atr ?
test-optimization-playwright-latest-oldest-playwright-final-status ?
test-optimization-playwright-latest-oldest-playwright-impacted-tests ?
test-optimization-playwright-latest-oldest-playwright-reporting ?
test-optimization-playwright-latest-oldest-playwright-test-management ?
test-optimization-playwright-oldest-latest-playwright-active-test-span ?
test-optimization-playwright-oldest-latest-playwright-atr ?
test-optimization-playwright-oldest-latest-playwright-efd ?
test-optimization-playwright-oldest-latest-playwright-final-status ?
test-optimization-playwright-oldest-latest-playwright-impacted-tests ?
test-optimization-playwright-oldest-latest-playwright-reporting ?
test-optimization-playwright-oldest-latest-playwright-test-management 44.56% <ø> (+0.11%) ⬆️
test-optimization-playwright-oldest-oldest-playwright-active-test-span ?
test-optimization-playwright-oldest-oldest-playwright-atr ?
test-optimization-playwright-oldest-oldest-playwright-efd ?
test-optimization-playwright-oldest-oldest-playwright-final-status ?
test-optimization-playwright-oldest-oldest-playwright-reporting ?
test-optimization-playwright-oldest-oldest-playwright-test-management ?
test-optimization-selenium-latest ?
test-optimization-selenium-oldest ?
test-optimization-testopt-latest ?
test-optimization-testopt-maintenance ?
test-optimization-testopt-oldest ?
test-optimization-vitest-latest ?
test-optimization-vitest-oldest 47.50% <ø> (-0.30%) ⬇️

Flags with carried forward coverage won't be shown. Click here to find out more.

☔ View full report in Codecov by Harness.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

dd-octo-sts Bot pushed a commit that referenced this pull request Jun 26, 2026
packages/dd-trace/test/guardrails/index.spec.js duplicated existing
integration coverage. init.spec.js's "when node version is too recent"
context already exercises the incompatible-runtime bailout — plus the
telemetry, debug logs, and DD_INJECT_FORCE override that the unit test
stubbed to no-ops — by setting pkg.nodeMaxMajor = NODE_MAJOR.

The unit test was added in #9033 only to satisfy a Codecov patch-coverage
flag on lines that PR added to the bailout block (integration tests run
in sandboxes and don't count toward nyc). It relied on proxyquire
intercepting an in-function require() of package.json, which is
environment-dependent: it failed on the v5.110.0 release proposal on
Node 26 even though the real bailout — verified by the passing
init.spec.js integration test on that same run — works correctly.

Co-authored-by: Claude Opus 4.8 (1M context) <[email protected]>
@dd-octo-sts dd-octo-sts Bot mentioned this pull request Jun 26, 2026
pabloerhard pushed a commit that referenced this pull request Jun 26, 2026
packages/dd-trace/test/guardrails/index.spec.js duplicated existing
integration coverage. init.spec.js's "when node version is too recent"
context already exercises the incompatible-runtime bailout — plus the
telemetry, debug logs, and DD_INJECT_FORCE override that the unit test
stubbed to no-ops — by setting pkg.nodeMaxMajor = NODE_MAJOR.

The unit test was added in #9033 only to satisfy a Codecov patch-coverage
flag on lines that PR added to the bailout block (integration tests run
in sandboxes and don't count toward nyc). It relied on proxyquire
intercepting an in-function require() of package.json, which is
environment-dependent: it failed on the v5.110.0 release proposal on
Node 26 even though the real bailout — verified by the passing
init.spec.js integration test on that same run — works correctly.

Co-authored-by: Claude Opus 4.8 (1M context) <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants