test(agama): add transpiler finish and log codegen conformance tests#14488
test(agama): add transpiler finish and log codegen conformance tests#14488imran-ishaq wants to merge 2 commits into
Conversation
Signed-off-by: imran <imranishaq7071@gmail.com>
|
No actionable comments were generated in the recent review. 🎉 ℹ️ Recent review info⚙️ Run configurationConfiguration used: Organization UI Review profile: ASSERTIVE Plan: Pro Run ID: 📒 Files selected for processing (1)
📝 WalkthroughWalkthroughAdds a TestNG test that transpiles a DSL flow containing Log and Finish statements, verifies generated JavaScript calls and literal values, and registers the test in the suite configuration. ChangesFinish and Log Test
Estimated code review effort: 1 (Trivial) | ~5 minutes Possibly related issues
🚥 Pre-merge checks | ✅ 4 | ❌ 1❌ Failed checks (1 warning)
✅ Passed checks (4 passed)
✨ Finishing Touches📝 Generate docstrings
🧪 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 |
✅ Snyk checks have passed. No issues have been found so far.
💻 Catch issues earlier using the plugins for VS Code, JetBrains IDEs, Visual Studio, and Eclipse. |
…tead of inline Java Signed-off-by: imran <imranishaq7071@gmail.com>
|



Prepare
Description
Adds
FinishAndLogTestto the Agama transpiler module. It transpiles a flow that logs and finishes with a userId, and asserts the generated JavaScript contains the logging call, the flow-finish call and the finish value. Registered in the module's TestNG suite. No production change — confirms current code generation conforms to the language reference.Target issue
The transpiler's Log and Finish statements are covered only by syntax-pass tests; nothing asserts they generate the expected runtime calls (logging call, flow-finish call) and carry the finish value, so a code-generation regression could go unnoticed.
closes #14487
Implementation Details
agama/transpiler/src/test/java/io/jans/agama/test/FinishAndLogTest.javausingTranspiler.transpileandasserting on the generated code.
agama/transpiler/src/test/resources/testng.xml.Test and Document the changes
Please check the below before submitting your PR. The PR will not be merged if there are no commits that start with
docs:to indicate documentation changes or if the below checklist is not selected.Summary by CodeRabbit