Skip to content

Restore @Test on ClusterConfigParserTest.testShellOutputMain - #6604

Merged
dlmarion merged 1 commit into
apache:mainfrom
sharanggupta:add-missing-test-annotation-ClusterConfigParserTest
Oct 23, 2026
Merged

dlmarion merged 1 commit into
apache:mainfrom
sharanggupta:add-missing-test-annotation-ClusterConfigParserTest

Conversation

@sharanggupta

Copy link
Copy Markdown
Contributor

testShellOutputMain was removed when ClusterConfigParserTest moved to the server module in #5749. When #5865 moved the class back to core, the method came back without its @Test annotation, so JUnit has skipped it since. This puts the annotation back. The test checks that ClusterConfigParser.main writes the expected shell variables to the output file given as its second argument. It now passes the configuration file as Path.of(configFile.toURI()), like the other tests, because URL.getFile() is URL-encoded and would break on a path with spaces.

mvn -pl core -am test -Dtest=ClusterConfigParserTest (JDK 21): 12 tests, 0 failures, with testShellOutputMain now among them. Formatter, impsort and checkstyle are clean.

The test was moved to the server module in apache#5749 and moved back to core
in apache#5865. When it was restored, the @test annotation was left off, so
JUnit has not run it since. Put the annotation back so the main()
output-file path of ClusterConfigParser is covered again, and pass the
configuration file as Path.of(URL.toURI()) like the other tests, since
URL.getFile() is URL-encoded.
@dlmarion

Copy link
Copy Markdown
Contributor

@sharanggupta - Thanks for the contribution. Feel free to open a PR on the website repo if you want to add your name to the contributors list (https://github.com/apache/accumulo-website/blob/main/pages/people.md)

@dlmarion
dlmarion merged commit a706526 into apache:main Oct 23, 2026
8 checks passed
@ctubbsii ctubbsii added this to the 4.0.0 milestone Oct 23, 2026
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.

4 participants