views:

201

answers:

1

com.xpn.xwiki.test.AbstractXWikiComponentTestCase

This is the only class that cannot be resolved. I have run

mvn package

Then I have tried to build with sourceanalyzer and this is the only class that cannot be found. I do not understand why mvn package would not have gotten this for me.

Any help would be great.

Thanks

A: 

Looks like you're missing a jar. did you see any lines earlier in the build attempting to download dependencies?

The XWiki jars aren't hosted on central, but you can add the XWiki repository to your pom using configuration like this:

<repositories>
  <repository>
    <id>xwiki-releases</id>
    <name>XWiki Maven2 Remote Repository for Releases</name>
    <url>http://maven.xwiki.org/releases&lt;/url&gt;
    <releases>
      <enabled>true</enabled>
    </releases>
    <snapshots>
      <enabled>false</enabled>
    </snapshots>
  </repository>
</repositories>

Once that configuration is added, Maven should download all the required dependencies. If it still doesn't, you can explicitly add the missing dependency to your POM:

<dependencies>
  ...
  <dependency>
    <groupId>org.xwiki.platform</groupId>
    <artifactId>xwiki-core-shared-tests</artifactId>
    <version>??</version>
    <scope>test<!--assume this is just for tests, if not omit the scope declaration--></scope>
  </dependency>
</dependencies>
Rich Seller