Skip to Content.
Sympa Menu

mace-opensaml-users - Re: [OpenSAML] building in maven on eclipse

Subject: OpenSAML user discussion

List archive

Re: [OpenSAML] building in maven on eclipse


Chronological Thread 
  • From: Brent Putman <>
  • To:
  • Subject: Re: [OpenSAML] building in maven on eclipse
  • Date: Fri, 28 Mar 2008 14:44:45 -0400



Kenny Pearce wrote:
Hi again,
I just downloaded the latest xmltooling into Eclipse 3.3 with the
Maven
integration plugin version 0.9, and when I try to run the "package" goal
I get a bunch of errors. To be precise: 54 failures and 10 errors occur
in the junit tests (but compile is fine). Most of the errors are similar
to this one:

junit.framework.AssertionFailedError: Unable to retrieve unmarshaller by
DOM Element
at junit.framework.Assert.fail(Assert.java:47)
at
org.opensaml.xml.XMLObjectBaseTestCase.unmarshallElement(XMLObjectBaseTestCase.java:150)
at
org.opensaml.xml.encryption.ChainingEncryptedKeyResolverTest.testEmptyChain(ChainingEncryptedKeyResolverTest.java:47)


Yes, there is some issue with the tests failing when using the equivalent of 'mvn test' or one of the phases that implies that. I have traced it to some weird and perplexing classloading and resource issuse that affects the way that providers are loaded when the tests are run. No resolution yet.

Will just made the Maven conversion yesterday, but he's out today I think, hopefully we should be get it figured out soon.
Outside of the Maven environment, all tests currently pass 100% successfully in all 3 projects (xmltooling, openws, opensaml2). It's not the tests themselves, it's the Maven environment.

You can bypass the tests by using -D args as specified here, that will at least let you package successfully:
http://maven.apache.org/plugins/maven-surefire-plugin/examples/skipping-test.html



There are also some PKIX/signature/security exceptions in the Maven
output, but the tests involved say they succeeded.

Those are from tests which are testing expected failure conditions, so things logged at ERROR level and exception output are expected. If the test says it passes, then it passed (e.g. the code failed in the expected manner). Nothing to worry about.


Are there additional requirements for building in maven that are not
yet listed on the web-site?


Not that I know of, but Will is our Maven expert.

Which Maven plugin are you using? The one that I know Will and I are using is the latest version of:
http://m2eclipse.codehaus.org/

Don't know if that's the one you meant you were using.

For what it's worth the tests that fail via 'mvn test' do pass when I run them individually in Eclipse. But the Eclipse environment, even with the plugin, apparently sets up the environment completely different from the way command-line mvn does. At least the way things are currently configured, we may have some tweaking to do.

--Brent





Archive powered by MHonArc 2.6.16.

Top of Page