Repository navigation
Validate Karate, ScalaTest and MUnit with paired feature controls - #255
Conversation
|
/datadog autotest review |
Codex Review SummaryThis comment shows the latest Codex review activity on this pull request.
ℹ️ About Codex in GitHubYour team has set up Codex to review pull requests in this repo. Reviews are triggered when you
Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings. |
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: 0fddf15858
ℹ️ 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".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
🎉 All green!🧪 All tests passed 🎯 Code Coverage (details) 🔗 Commit SHA: feeca0d | Docs | View more details | Give us feedback! |
There was a problem hiding this comment.
Karate’s report parser can treat different multiline assertion failures as identical and incorrectly report compatibility. Valid ScalaTest/Surefire and Karate runner configurations can also leave all feature checks inconclusive.
🤖 Bits Code Review · Commit 0fddf15
|
/datadog autotest review |
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: d9be9f989d
ℹ️ 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".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
There was a problem hiding this comment.
ScalaTest feature validation cannot complete for reactors with multiple ScalaTest modules or projects using modular dependencies without AnyFunSuite. The probe selection applies across the reactor, while its generated source assumes a suite dependency that those projects may lack.
🤖 Bits Code Review · Commit d9be9f9
|
/datadog autotest review |
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: f76d6a0713
ℹ️ 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".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
There was a problem hiding this comment.
ScalaTest commands that already specify -Dsuites retain that selector during probe runs, causing existing suites to run alongside the probe and making all feature checks inconclusive.
🤖 Bits Code Review · Commit f76d6a0
There was a problem hiding this comment.
Explicit ScalaTest suite filters and Karate helper classes can prevent isolated probe execution, leaving feature validation inconclusive for otherwise runnable projects.
🤖 Bits Code Review · Commit f76d6a0
Karate results come from its feature reports, ScalaTest's from the scalatest-maven-plugin's reports. MUnit and ScalaTest probes are Scala suites; the Karate probe is a feature run through the module's runner. dd-java-agent cannot skip MUnit tests, so those features are not supported. Co-Authored-By: Claude Opus 5.5 <[email protected]>
Each @Karate.Test method of a runner would run the probe feature. Co-Authored-By: Claude Opus 5.5 <[email protected]>
Co-Authored-By: Claude Opus 5.5 <[email protected]>
Co-Authored-By: Claude Opus 5.5 <[email protected]>
…nit runner - A Karate runner must declare @Karate.Test, @RunWith(Karate.class) or call Runner.path/builder; importing Karate's types is not enough. The probe selects the @Karate.Test method, else the test that calls the Runner. - Karate failures keep every line of the error, so differing match values do not compare equal. - A ScalaTest probe declares the JUnitRunner of the module's suites, which Surefire needs to run it. - Surefire 3.5 omits "There are test failures" when every failure is an error; that build is no longer treated as incomplete. Co-Authored-By: Claude Opus 5.5 <[email protected]>
…nners - The probe selects its suite with wildcardSuites: with suites, every other module the scalatest-maven-plugin runs fails for lack of the probe. - A @RunWith(classOf[JUnitRunner]) counts as ScalaTest's when the source names the runner's package, as wildcard and selective imports do. Co-Authored-By: Claude Opus 5.5 <[email protected]>
A command's own -Dsuites would run its suites alongside the probe. Co-Authored-By: Claude Opus 5.5 <[email protected]>
A helper that calls the Runner outside any test cannot be selected. Co-Authored-By: Claude Opus 5.5 <[email protected]>
855680c to
feeca0d
Compare
What
ddtest testdrivenow runs paired validation (baseline vs reporting-only, plus the six feature probes) for Karate, ScalaTest and Scala MUnit on Maven. Before this PR they got reporting-only checks.target/karate-reports/*.karate-json.txt. Surefire's copies of Karate scenarios are unreliable. The probe is a feature run through the module's Karate runner with-Dkarate.options, selecting one runner method; the runner's own JUnit result is left out.target/scalatest-reports, and its goal counts as a test goal. The probe is anAnyFunSuite, selected with-Dsuitesand-Dtest. It declares the module'sJUnitRunnerwhen Surefire runs the suites. dd-java-agent 1.67.1 and 1.68.0 currently fail every test of such a suite, and validation reports that as a suspected regression.munit.FunSuite. Skipping and disabled are reported as not supported: dd-java-agent skips JUnit 4 tests throughParentRunner, andMUnitRunnerdoesn't extend it.Shared changes:
maven.ReadReportsreads the two new report formats.maven.IncompleteBuildaccepts Surefire 3.5's failure line for a build whose failed tests are all errors. Before, such a build was treated as incomplete.Why
Customers using these frameworks could not get a COMPLETE local verdict: features were never exercised. This finishes Maven framework coverage after #253.
E2E testing
Prerequisites: Docker, or a host with JDK 17+, Maven 3.9 and git. Build ddtest from this branch with
make build. Run every command below with network access to Maven Central.fixtures.shcreates three fixture projects under./e2esh fixtures.sh.cd e2e/karate && ddtest testdrive --framework karate --yes.Compatibility (this invocation): compatible.Feature …: passedlines andLocal validation: PASSED, with exit 0.cd e2e/scalatest && ddtest testdrive --framework scalatest --yes. Expect the same result: compatible, six features passed,Local validation: PASSED.cd e2e/munit && ddtest testdrive --framework munit --yes.Feature skipping: not supportedandFeature disabled: not supported, naming MUnit's runner.Local validation: PASSED.e2e/karate, replacesrc/test/java/example/KarateTest.javawith a plain JUnit 5 test ofCalc, then re-run step 2's command.inconclusivewith "No Karate runner class … in the test sources of the root module", andLocal validation: INCOMPLETEwith exit 1.git statusin the fixture shows notarget/and noddtestprobe files. Only.testoptimization/is added.rm -rf e2e.🤖 Generated with Claude Code