Skip to content

[#244] Removed @Disabled from DefaultPackageAddTestCase.testAddDefaultPackage() - #267

Merged
xjusko merged 1 commit into
shrinkwrap:mainfrom
AnkitKumar-05:issue-244
Oct 6, 2026
Merged

xjusko merged 1 commit into
shrinkwrap:mainfrom
AnkitKumar-05:issue-244

Conversation

@AnkitKumar-05

Copy link
Copy Markdown
Contributor

fixes: #244

Excludes module-info.class from URLPackageScanner in both directory and archive scanning paths, since it is a Java module descriptor, not a class belonging to any package.

Re-enables DefaultPackageAddTestCase.testAddDefaultPackage().

@AnkitKumar-05 AnkitKumar-05 changed the title [244] Removed @Disabled from DefaultPackageAddTestCase.testAddDefaultPackage() [#244] Removed @Disabled from DefaultPackageAddTestCase.testAddDefaultPackage() Sep 28, 2026

@xjusko xjusko left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks, @AnkitKumar-05. It looks good; just one small note worth changing, I think.

ZipEntry entry = entries.nextElement();
String name = entry.getName();
if (name.startsWith(prefix + packageNamePath) && name.endsWith(SUFFIX_CLASS)
&& !name.endsWith("module-info" + SUFFIX_CLASS)

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Could you pull this into a constant next to SUFFIX_CLASS?

private static final String MODULE_INFO_CLASS = "module-info" + SUFFIX_CLASS;

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks, @xjusko. Done!

@xjusko
xjusko merged commit 4c7c658 into shrinkwrap:main Oct 6, 2026
6 checks passed
@AnkitKumar-05
AnkitKumar-05 deleted the issue-244 branch October 6, 2026 10:51
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.

Remove @Disabled from DefaultPackageAddTestCase.testAddDefaultPackage()

2 participants