Add Java TestNG emit kit#1633
Conversation
|
Warning Review limit reached
More reviews will be available in 55 minutes and 42 seconds. Learn how PR review limits work. Your organization has run out of usage credits. Purchase more in the billing tab. ⌛ How to resolve this issue?After more reviews become available, a review can be triggered using the We recommend that you space out your commits to avoid hitting the rate limit. 🚦 How do rate limits work?CodeRabbit enforces hourly rate limits for each developer per organization. Our paid plans include higher PR review limits than trial, open-source, and free plans. In all cases, reviews become available again over time. During sustained high-volume PR review activity, CodeRabbit may temporarily slow when the next review becomes available. Please see our Fair Usage Limits Policy for further information. ℹ️ Review info⚙️ Run configurationConfiguration used: Organization UI Review profile: CHILL Plan: Pro Run ID: 📒 Files selected for processing (15)
✨ Finishing Touches🧪 Generate unit tests (beta)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: d6099b4224
ℹ️ 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".
| for (String v : vars) { | ||
| String type = declaredTypes.getOrDefault(v, fallbackType); | ||
| decls.add(type + " " + v + " = " + defaultValueFor(type) + ";"); |
There was a problem hiding this comment.
Generate placeholders that satisfy executed TestNG assertions
When a plan contains supported predicates beyond the all-zero cases, these per-variable defaults make the emitted TestNG methods fail at runtime even though the emission reports is_complete: e.g. ne, lt, and gt declare both operands as 0, option-is-some/not-null declare Object ... = null, and fallible-err gets a non-throwing null value. Since this kit's compile check actually runs mvn -q test in RpcServer.checkResult, provekit emit --compile-check fails for contracts the plugin advertises as supported; the placeholders need to be chosen per predicate/argument (as the other emitters do) or these predicates should be left unsupported.
Useful? React with 👍 / 👎.
Summary
provekit-emit-java-testngas a separate Java emitter artifactjava-testngthrough project config and emit manifestorg.testng.annotations.Testandorg.testng.AssertVerification
mvn -B -ntp -pl provekit-emit-java-testng -am packagecargo test -p provekit-cli --test cmd_emit_java_testng --manifest-path implementations/rust/Cargo.toml emit_java_testng_dispatches_real_emitter_and_maven_checks_output -- --nocapturecargo fmt --manifest-path implementations/rust/provekit-cli/Cargo.toml --checkgit diff --checkNote: Maven prints the existing reactor warnings for
provekit-lift-java-term-shapeand the normal shade MANIFEST overlap warning; the build passes.