Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix pathname encoding in the component test library #40640

Merged
merged 3 commits into from
May 16, 2024

Conversation

FWest98
Copy link
Contributor

@FWest98 FWest98 commented May 14, 2024

The component test library did not properly decode the URI file path, causing characters like spaces in the path to break tests. For example, in the old setup:

String testPath = testClass.getClassLoader().getResource(testClassResourceName).getFile();
// returns "/foo/foo%20bar/org/acme/Foo.class"

String testClassesRootPath = ...
// yields "/foo/foo%20bar"

testOutputDirectory = new File(testClassesRootPath);
// file not found, tests break

The component test library did not properly decode the URI file path, causing characters like spaces in the path to break tests.
@gsmet gsmet requested review from geoand and dmlloyd May 15, 2024 07:56
@geoand
Copy link
Contributor

geoand commented May 15, 2024

Any chance you could add a test for this?

@FWest98
Copy link
Contributor Author

FWest98 commented May 15, 2024

I was looking into that, but I think the only way to do so is to create a new subproject somewhere with a special character in its name, and then add a test there. I was not quite sure whether that's desired, and if so, how to proceed with that.

In case the extra subproject is still desired for this, could you give me some directions on how to approach it?

@quarkus-bot
Copy link

quarkus-bot bot commented May 16, 2024

Status for workflow Quarkus CI

This is the status report for running Quarkus CI on commit 9c71d7a.

✅ The latest workflow run for the pull request has completed successfully.

It should be safe to merge provided you have a look at the other checks in the summary.

You can consult the Develocity build scans.

@geoand geoand merged commit c97fb19 into quarkusio:main May 16, 2024
22 checks passed
@quarkus-bot quarkus-bot bot added this to the 3.12 - main milestone May 16, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants