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

EmptyBeansXmlDiscoveryTest has incorrect deployment configuration #470

Closed
manovotn opened this issue Jun 2, 2023 · 2 comments · Fixed by #471
Closed

EmptyBeansXmlDiscoveryTest has incorrect deployment configuration #470

manovotn opened this issue Jun 2, 2023 · 2 comments · Fixed by #471
Assignees
Labels
accepted Issue/challenge is accepted challenge TCK test challenge

Comments

@manovotn
Copy link
Contributor

manovotn commented Jun 2, 2023

In my attempt to update Arquillian deps in Weld(weld/core#2846), I noticed that EmptyBeansXmlDiscoveryTest started failing.
A recent fix in Arquillian (arquillian/arquillian-core#440) correctly exposes erroneous setup of this test which was previously falsely passing and would pass regardless of what would be in the test.

Underlying cause is a NoClassDefFound error and further digging showed that the test deployment lacks the AbstractTest superclass (and possibly other classes).
Said test uses a manual setup via ShrinkWrap.create(WebArchive.class).addClasses(...) (beucase it needed a truly empty beans.xml added) whereas other TCK tests use WebArchiveBuilder() API. Turns out WebArchiveBuilder does a bunch of things for the test automagically, including adding AbstractTest class into the deployment.

The test can be easily rewritten to make use of the WebArchiveBuilder which solves the issue and should make it (correctly) pass on al Arq. versions. I have the changes locally and will submit a PR.

Since this problem is a combination of testng and Arq. core version, not all impls and test setups are affected - especially since you can do a lot of tweaks in Arq. adapters that each impl is using. Nonetheless, the test setup is still wrong. I wonder if perhaps Liberty is also seeing this if they update Arq. core to 1.7.0.Final, maybe @Azquelt knows?

@manovotn manovotn added the challenge TCK test challenge label Jun 2, 2023
@manovotn manovotn self-assigned this Jun 2, 2023
@Ladicek Ladicek added the accepted Issue/challenge is accepted label Jun 6, 2023
@Azquelt
Copy link
Member

Azquelt commented Jun 12, 2023

When this was raised, we were still using an older version of arquillian. When we upgraded to 1.7.0.Final, we do indeed have the same problem.

@manovotn
Copy link
Contributor Author

When this was raised, we were still using an older version of arquillian. When we upgraded to 1.7.0.Final, we do indeed have the same problem.

Thanks for verifying!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
accepted Issue/challenge is accepted challenge TCK test challenge
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants