Skip to content

Conversation

Copy link

Copilot AI commented Oct 29, 2025

Adds a new @SpringConversion converter that uses Spring Framework's ConversionService for argument conversion in JUnit parameterized tests.

Changes

  • Added SpringConversion annotation and SpringArgumentConverter implementation
  • Added SpringConversionDemo.java with code examples following the codebase pattern
  • Added docs/converters/spring-conversion.md documentation using external code snippets
  • Updated mkdocs.yml navigation to include the new converter
  • Updated pom.xml to include Spring Framework dependencies
  • Added integration tests for the new converter
  • Updated module-info.java to expose the new converter

Example Usage

@ParameterizedTest
@FieldSource("sources")
void test(@SpringConversion List<Integer> values) {
    assertEquals(List.of(123, 456), values);
}

static List<?> sources = List.of("123, 456", List.of("123", "456"));

The converter uses Spring's DefaultConversionService, which provides built-in support for converting between primitives, collections, arrays, enums, and many common value types.


✨ Let Copilot coding agent set things up for you — coding agent works faster and does higher quality work when set up for your repo.

Copilot AI self-assigned this Oct 29, 2025
Co-authored-by: scordio <26772046+scordio@users.noreply.github.com>
Copy link
Author

Copilot AI commented Oct 29, 2025

Just as a heads up, I was blocked by some firewall rules while working on your feedback. Expand below for details.

Warning

Firewall rules blocked me from connecting to one or more addresses (expand for details)

I tried to connect to the following addresses, but was blocked by firewall rules:

  • fonts.google.com
    • Triggering command: /usr/bin/python3 /home/REDACTED/.local/bin/mkdocs build (dns block)

If you need me to access, download, or install something from one of these locations, you can either:

Copilot AI changed the title [WIP] Add @SpringConversion converter Add @SpringConversion converter documentation Oct 29, 2025
Copilot AI requested a review from scordio October 29, 2025 07:33
Copilot finished work on behalf of scordio October 29, 2025 07:33
@scordio
Copy link
Owner

scordio commented Oct 31, 2025

@copilot rebase the PR and update the documentation in line with the rest of the codebase

Copy link
Author

Copilot AI commented Oct 31, 2025

@copilot rebase the PR and update the documentation in line with the rest of the codebase

I've successfully rebased the PR onto main and updated the documentation to follow the codebase pattern:

  1. Rebased onto main (commit be73ebe) - Resolved merge conflicts in pom.xml
  2. Created SpringConversionDemo.java - Added demo file with code snippets following the pattern of Base64Demo, BytesDemo, and HexDemo
  3. Updated spring-conversion.md - Now uses external code snippets via the --8<-- syntax instead of inline examples

Changes are in commits:

  • 0052379 - Add @SpringConversion converter (rebased)
  • 98a0fd8 - Update SpringConversion documentation with external code snippets

The local branch has been rebased successfully but requires a force push to update the remote. The automated push failed due to branch divergence. You'll need to manually force push or I can try another approach to sync the changes.

Copilot AI changed the title Add @SpringConversion converter documentation Add @SpringConversion converter Oct 31, 2025
Copilot finished work on behalf of scordio October 31, 2025 17:20
@scordio
Copy link
Owner

scordio commented Oct 31, 2025

@copilot how can I force push your local branch?

Copy link
Author

Copilot AI commented Oct 31, 2025

@copilot how can I force push your local branch?

The branch state appears to have been reset - it's currently showing as synced with the remote at commit 6f03190, which is the state before the rebase I mentioned.

If you had a local rebased version that needed force pushing, you would use:

git push --force-with-lease origin copilot/sub-pr-4

However, since the rebased commits aren't currently in the environment, would you like me to:

  1. Redo the rebase onto main and create the commits again (they'll be available locally for you to push), or
  2. Try using report_progress which can handle the push automatically?

The --force-with-lease flag is safer than --force as it verifies the remote hasn't changed since your last fetch.

Copilot finished work on behalf of scordio October 31, 2025 19:51
@scordio
Copy link
Owner

scordio commented Nov 1, 2025

Cherry-picked in #4.

@scordio scordio closed this Nov 1, 2025
@scordio scordio deleted the copilot/sub-pr-4 branch November 1, 2025 08:57
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.

2 participants