Fork me on GitHub

Usage

The plugin offers goals for hosting a mock repository manager as part of a Maven project lifecycle.

Basic Usage

Before you start it is best to add mrm-maven-plugin as a plugin in your pom.

<project>
  ...
  <build>
    ...
    <plugins>
      ...
      <plugin>
        <groupId>org.codehaus.mojo</groupId>
        <artifactId>mrm-maven-plugin</artifactId>
        <version>1.1.0</version>
      </plugin>
      ...
    </plugins>
    ...
  </build>
  ...
</project>

Start up a test Mock Repository Manager

To start up a test Mock Repository Manager to allow you to develop your tests using your favorite IDE, invoke the run goal.

mvn mrm:run

You can change the port that the mock repository manager binds to either using the mrm.port property from the command line, e.g.

mvn mrm:run -Dmrm.port=8080

Or in the configuration block in the plugin definition (which has the advantage that all invocations will use the same parameters).

<project>
  ...
  <build>
    ...
    <plugins>
      ...
      <plugin>
        <groupId>org.codehaus.mojo</groupId>
        <artifactId>mrm-maven-plugin</artifactId>
        <version>1.1.0</version>
        <configuration>
          <port>8080</port>
        </configuration>
      </plugin>
      ...
    </plugins>
    ...
  </build>
  ...
</project>