Skip to content

[SHRINKWRAP-541] Updating jUnit from 4 to jUnit 5 - #172

Merged
petrberan merged 1 commit into
shrinkwrap:mainfrom
khermano:SHRINKWRAP-541_from_main
Aug 8, 2024
Merged

petrberan merged 1 commit into
shrinkwrap:mainfrom
khermano:SHRINKWRAP-541_from_main

Conversation

@khermano

@khermano khermano commented Aug 5, 2024

Copy link
Copy Markdown
Contributor

@khermano
khermano force-pushed the SHRINKWRAP-541_from_main branch from 9462d05 to 9087baf Compare August 6, 2024 14:24
Comment thread pom.xml Outdated

<!-- Versions of test dependencies -->
<version.junit>4.13.2</version.junit>
<version.org.junit-jupiter>5.11.0-M2</version.org.junit-jupiter>

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

Not sure we want to use M2 versions here

try {
new ClassAsset(null);
Assert.fail("Should have thrown IllegalArgumentException");
Assertions.fail("Should have thrown IllegalArgumentException");

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

Should this use assertThrows?

*
* SHRINKWRAP-233, SHRINKWRAP-302
*
* DISABLED - After replacing JUnit 4 with JUnit 5 the test is failing - size of archive should be 3 but is 4

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

Do we have an issue filed for that?

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.

Yes, the issue already exists. I will add it to the comment, too, so it's clearer where to find it. It's this one: https://issues.redhat.com/browse/SHRINKWRAP-543. It's also linked to the JIRA.

final File nonZipFile = new File(TestSecurityActions.getThreadContextClassLoader()
.getResource(NAME_FILE_NON_ZIP).toURI());
ShrinkWrap.createFromZipFile(JavaArchive.class, nonZipFile);
InputStream inputStream = TestSecurityActions.getThreadContextClassLoader()

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

It would be much easier to move the file to this module's resources

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.

That was a quick temporary solution which I missed to repair. Sorry about that.

@khermano
khermano force-pushed the SHRINKWRAP-541_from_main branch from 9087baf to 7c5a591 Compare August 8, 2024 10:52

@petrberan petrberan left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

Great job @khermano , thanks

@petrberan
petrberan merged commit c907b7e into shrinkwrap:main Aug 8, 2024
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