Add integration tests for skill templates#15131
Open
rishic3 wants to merge 9 commits into
Open
Conversation
Signed-off-by: Rishi Chandra <rishic@nvidia.com>
Contributor
Contributor
There was a problem hiding this comment.
Pull request overview
Adds a new skills/tests/ pytest suite that integration-tests the JVM skill templates end-to-end by materializing a template project, filling in TODO stubs with deterministic fixtures (including CPU/RapidsUDF/SQL/CUDA-native variants), and then running mvn builds plus the provided benchmark scripts to ensure the templates work “out of the box”.
Changes:
- Add integration tests that generate a temporary project from the JVM templates, fill stubs, build, and execute template test/benchmark flows for
(scala|java) x (cudf|sql|cuda). - Add fixtures and resource source files used to populate template TODOs and native CUDA/JNI placeholders.
- Add skill frontmatter parsing tests, plus Python dev/test configuration and a testing doc.
Reviewed changes
Copilot reviewed 16 out of 16 changed files in this pull request and generated 5 comments.
Show a summary per file
| File | Description |
|---|---|
| skills/tests/utils.py | Test helpers for running Maven/scripts and patching Scala TODO stubs. |
| skills/tests/test_jvm_templates.py | Main integration test suite that builds/runs the materialized template project across targets. |
| skills/tests/test_frontmatter.py | Lightweight test to ensure all SKILL.md YAML frontmatter parses and has key fields. |
| skills/tests/fixtures.py | Loads resource files and provides stub method implementations used to fill template TODOs. |
| skills/tests/init.py | Marks skills/tests as a Python package for relative imports. |
| skills/tests/resources/IntegerMultiplyBy2UDF.scala | Scala CPU UDF reference implementation used by the tests. |
| skills/tests/resources/IntegerMultiplyBy2UDF.java | Java CPU UDF reference implementation used by the tests. |
| skills/tests/resources/IntegerMultiplyBy2RapidsUDF.scala | Scala RapidsUDF implementation used by the tests. |
| skills/tests/resources/IntegerMultiplyBy2RapidsUDF.java | Java RapidsUDF implementation used by the tests. |
| skills/tests/resources/IntegerMultiplyBy2NativeRapidsUDF.java | Java wrapper for the native CUDA UDF used by the tests. |
| skills/tests/resources/IntegerMultiplyBy2Jni.cpp | JNI bridge source used by the native CUDA target tests. |
| skills/tests/resources/integer_multiply_by_2.sql | SQL implementation used by the SQL target tests. |
| skills/tests/resources/integer_multiply_by_2.hpp | Native header used by the CUDA target tests. |
| skills/tests/resources/integer_multiply_by_2.cu | Native CUDA implementation used by the CUDA target tests. |
| skills/pyproject.toml | Python dev dependencies + pytest marker registration for skills/ tests. |
| skills/docs/dev/TESTING.md | Developer docs for running fast vs integration tests under skills/. |
Co-authored-by: Copilot Autofix powered by AI <175728472+Copilot@users.noreply.github.com>
8 tasks
8 tasks
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Contributes to #15013.
Description
Adds integration tests for skill templates. (These were originally included in #15058 but were deferred into this separate PR). The tests basically verify that the templates work out of the box: builds work, scripts run, validations catch errors they're supposed to catch, etc.
The tests create a dummy project, deterministically fill in all of the TODO methods (using the method stubs under
fixtures) and add UDF implementations (using the complete source files underresources), and then run the sequence of scripts that the agent would go through.Checklists
Documentation
Testing
(Please provide the names of the existing tests in the PR description.)
Performance