Skip to content

Unify test frameworks. Step 01 Laravel8 - #4149

Open
estringana wants to merge 3 commits into
masterfrom
estringana/unify-frameworks
Open

Unify test frameworks. Step 01 Laravel8#4149
estringana wants to merge 3 commits into
masterfrom
estringana/unify-frameworks

Conversation

@estringana

@estringana estringana commented Aug 28, 2026

Copy link
Copy Markdown
Contributor

Why this PR exists

Now when we add appsec coverage to a new framework, we maintain two separate copies of it:

  • tests/Frameworks//Version_X/ — used by tracer integration tests
  • appsec/tests/integration/src/test/www// — a duplicate used by appsec integration tests

This made sense historically but we are in the same repository now moving into a more unified experience.

Due to this duplication, whenever we have to test something in addition to duplicate the framework, we have to duplicate the endpoints. Like it happened with all authentication features.

The proposal

Retire the appsec-side duplicates and point the appsec integration test container at the canonical copy under tests/Frameworks/. Any routes or fixtures that appsec tests need get added directly to the shared framework. The tracer tests don't care about the extra routes, and appsec gets a richer, always-current environment for free.

This PR: Laravel 8x as the first step

  • Removes the standalone appsec/tests/integration/src/test/www/laravel8x/ copy
  • Adds the appsec-specific routes and fixtures (login, register, dynamic-path, endpoint discovery) to tests/Frameworks/Laravel/Version_8_x/
  • Updates Laravel8xTests.groovy to mount the shared path and target PHP 8.1 (matching the version the tracer already tests against)
  • All tracer test_web_laravel_8x jobs and all appsec integration test jobs pass

Next steps

  • Symfony 6.2
  • Laminas MVC 3.3
  • WordPress 6.1
  • Roadrunner

Not doing

  • llm
  • payment
  • frankenphp

Reviewer checklist

  • Test coverage seems ok.
  • Appropriate labels assigned.

@datadog-official

datadog-official Bot commented Aug 28, 2026

Copy link
Copy Markdown

Pipelines  Tests

Unblock PR with BitsAI

⚠️ Warnings

Your PR has failed checks. Please review the issues below and take necessary action before merging.

🚦 34 Pipeline jobs failed

DataDog/apm-reliability/dd-trace-php | ASAN Opcache tests: [8.2] — 🔧 Needs a code fix, caused by this PR

View more details · View in GitLab

DataDog/apm-reliability/dd-trace-php | ASAN Opcache tests: [8.4] — 🔧 Needs a code fix, caused by this PR

View more details · View in GitLab

DataDog/apm-reliability/dd-trace-php | ASAN init hook tests: [8.2] — 🔧 Needs a code fix, caused by this PR

View more details · View in GitLab

View all 34 failed jobs.

ℹ️ Info

No other issues found (see more)

🧪 All tests passed
❄️ No new flaky tests detected

🎯 Code Coverage (details)
Patch Coverage: 100.00%
Overall Coverage: 60.66% (-0.01%)

Useful? React with 👍 / 👎

This comment will be updated automatically if new data arrives.
🔗 Commit SHA: 5f52e5f | Docs | View more details | Give us feedback!

@pr-commenter

pr-commenter Bot commented Aug 28, 2026

Copy link
Copy Markdown

Benchmarks [ tracer ]

Benchmark execution time: 2026-08-31 17:04:57

Comparing candidate commit 5f52e5f in PR branch estringana/unify-frameworks with baseline commit 2e85cae in branch master.

Found 2 performance improvements and 4 performance regressions! Performance is the same for 188 metrics, 0 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 ----------------------------------'

scenario:SamplingRuleMatchingBench/benchRegexMatching1

  • 🟥 execution_time [+68.380ns; +151.620ns] or [+4.688%; +10.396%]

scenario:SamplingRuleMatchingBench/benchRegexMatching2

  • 🟥 execution_time [+64.906ns; +139.894ns] or [+4.473%; +9.640%]

scenario:SamplingRuleMatchingBench/benchRegexMatching3

  • 🟥 execution_time [+67.259ns; +148.941ns] or [+4.578%; +10.138%]

scenario:SamplingRuleMatchingBench/benchRegexMatching4

  • 🟥 execution_time [+96.284ns; +150.716ns] or [+6.685%; +10.464%]

scenario:TraceFlushBench/benchFlushTrace

  • 🟩 execution_time [-18.914µs; -9.386µs] or [-5.147%; -2.554%]

scenario:TraceFlushBench/benchFlushTrace-opcache

  • 🟩 execution_time [-21.321µs; -9.179µs] or [-5.822%; -2.507%]

@estringana estringana changed the title Unify appsec Laravel framework to tracer Unify test frameworks. Step 01 Laravel8 Aug 31, 2026
@estringana
estringana marked this pull request as ready for review August 31, 2026 12:47
@estringana
estringana requested review from a team as code owners August 31, 2026 12:47
@chatgpt-codex-connector

chatgpt-codex-connector Bot commented Aug 31, 2026

Copy link
Copy Markdown

Codex Review Summary

This comment shows the latest Codex review activity on this pull request.

Review Status Commit Review trigger
📝 Code Review Completed 2026-08-31T12:52:03.449884Z 7615537 Draft marked ready
ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review" or "@codex security review".

Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings.

@Leiyks Leiyks left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

lgtm overall 👍

Comment thread tests/Frameworks/Laravel/Version_8_x/initialize.sh Outdated
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants