Skip to content

[AI] Expand Test Coverage - eldritch-core#2378

Draft
KCarretto wants to merge 1 commit into
mainfrom
jules-eldritch-core-test-coverage-376885688499255364
Draft

[AI] Expand Test Coverage - eldritch-core#2378
KCarretto wants to merge 1 commit into
mainfrom
jules-eldritch-core-test-coverage-376885688499255364

Conversation

@KCarretto

Copy link
Copy Markdown
Collaborator

Expands test coverage for the eldritch-core module within the spellshift/realm repository limit to under 5 files.

This PR adds and extends missing coverage specifically focusing on:

  1. AST Offsets (analysis_extended.rs): Introduces comprehensive tests targeting find_node_at_offset checking variants across loops, conditionals, list comps, dictionary definitions, f-strings, lambda scopes, and functions.
  2. Type Extraction (conversion.rs): Exhaustively tests validation implementations extracting primitives, structs, and optionals from the Value AST enumeration while also catching errors.
  3. Tprint Formatter (tprint_extended.rs): Fills the gap on checking tprint macro bounds with malformed calls (e.g. empty argument lists, incorrect primitives like Int vs List of Dicts).

Modifications are confined to creating 3 distinct files within implants/lib/eldritch/eldritch-core/tests/ preserving standard styles and avoiding nondeterminism.


PR created automatically by Jules for task 376885688499255364 started by @KCarretto

Adds extended test files for `analysis`, `conversion`, and `tprint` modules in `eldritch-core`.

- `tests/analysis_extended.rs`: Tests AST iterating with `find_node_at_offset` logic over multiple variants.
- `tests/conversion.rs`: Tests valid/invalid `FromValue` and `ToValue` mapping paths.
- `tests/tprint_extended.rs`: Tests invalid argument patterns for printing format.

Co-authored-by: KCarretto <16250309+KCarretto@users.noreply.github.com>
@google-labs-jules

Copy link
Copy Markdown
Contributor

👋 Jules, reporting for duty! I'm here to lend a hand with this pull request.

When you start a review, I'll add a 👀 emoji to each comment to let you know I've read it. I'll focus on feedback directed at me and will do my best to stay out of conversations between you and other bots or reviewers to keep the noise down.

I'll push a commit with your requested changes shortly after. Please note there might be a delay between these steps, but rest assured I'm on the job!

For more direct control, you can switch me to Reactive Mode. When this mode is on, I will only act on comments where you specifically mention me with @jules. You can find this option in the Pull Request section of your global Jules UI settings. You can always switch back!

New to Jules? Learn more at jules.google/docs.


For security, I will only act on instructions from the user who triggered this task.

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.

1 participant