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

Introduce Mock Repository Manager #117

Merged
merged 6 commits into from
Feb 9, 2019
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 5 additions & 2 deletions .travis.yml
Original file line number Diff line number Diff line change
@@ -1,7 +1,10 @@
language: java
jdk:
- oraclejdk7
- oraclejdk8
- openjdk7
- openjdk8

dist: trusty

script: "mvn --show-version --errors --batch-mode -Prun-its clean verify"
cache:
directories:
Expand Down
11 changes: 10 additions & 1 deletion appveyor.yml
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,16 @@ install:
- cmd: SET MAVEN_OPTS=-Xmx768m
- cmd: mvn --version
- cmd: java -version

for:
-
matrix:
only:
- JAVA_HOME: C:\Program Files\Java\jdk1.7.0
build_script:
- mvn -B -Prun-its clean verify -Dhttps.protocols=TLSv1.2

build_script:
- mvn -B -Prun-its clean verify
- mvn -B -Prun-its clean verify
cache:
- C:\Users\appveyor\.m2
63 changes: 26 additions & 37 deletions pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -284,65 +284,54 @@
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-invoker-plugin</artifactId>
<version>3.2.0</version>
<configuration>
<addTestClassPath>true</addTestClassPath>
<debug>true</debug>
<localRepositoryPath>${project.build.directory}/local-repo</localRepositoryPath>
<cloneProjectsTo>${project.build.directory}/it</cloneProjectsTo>
<projectsDirectory>src/it</projectsDirectory>
<projectsDirectory>src/it/projects</projectsDirectory>
<showVersion>true</showVersion>
<setupIncludes>
<setupInclude>setup/pom.xml</setupInclude>
</setupIncludes>
<pomIncludes>
<pomInclude>*/pom.xml</pomInclude>
</pomIncludes>
<preBuildHookScript>setup</preBuildHookScript>
<postBuildHookScript>verify</postBuildHookScript>
<settingsFile>src/it/settings.xml</settingsFile>
<!--
! Currently working with more than one thread does not work,
! cause it is not guaranteed that the setup-config
! project is build at first.
! see also https://issues.apache.org/jira/browse/MINVOKER-147
-->
<parallelThreads>1</parallelThreads>
<settingsFile>src/it/mrm/settings.xml</settingsFile>
<properties>
<maven.compiler.source>${mojo.java.target}</maven.compiler.source>
<maven.compiler.target>${mojo.java.target}</maven.compiler.target>
<!-- e.g. ensure that Java7 picks up TLSv1.2 when connecting with Central -->
<https.protocols>${https.protocols}</https.protocols>
</properties>
<filterProperties>
<mrm.repository.url>${mrm.repository.url}</mrm.repository.url>
</filterProperties>
</configuration>
<executions>
<execution>
<id>pre-integration-tests</id>
<goals>
<goal>install</goal>
<goal>run</goal>
</goals>
<configuration>
<extraArtifacts>
<extraArtifact>org.apache.maven.plugins:maven-compiler-plugin:3.1:maven-plugin</extraArtifact>
<extraArtifact>org.apache.maven.plugins:maven-install-plugin:2.4:maven-plugin</extraArtifact>
<extraArtifact>org.apache.maven.plugins:maven-clean-plugin:2.5:maven-plugin</extraArtifact>
<extraArtifact>org.apache.maven.plugins:maven-surefire-plugin:2.16:maven-plugin</extraArtifact>
<extraArtifact>org.apache.maven.plugins:maven-assembly-plugin:2.4:maven-plugin</extraArtifact>
<extraArtifact>org.apache.maven.plugins:maven-jar-plugin:2.4:maven-plugin</extraArtifact>
<extraArtifact>org.apache.maven.plugins:maven-war-plugin:2.3:maven-plugin</extraArtifact>
<extraArtifact>org.apache.maven.plugins:maven-resources-plugin:2.6:maven-plugin</extraArtifact>
<extraArtifact>org.apache.maven.plugins:maven-site-plugin:3.3:maven-plugin</extraArtifact>
<extraArtifact>org.apache.maven.plugins:maven-site-plugin:2.0.1:maven-plugin</extraArtifact>
<extraArtifact>commons-io:commons-io:1.1:jar</extraArtifact>
<extraArtifact>commons-logging:commons-logging:1.0.4:jar</extraArtifact>
<extraArtifact>org.codehaus.plexus:plexus-utils:1.1:jar</extraArtifact>
</extraArtifacts>
</configuration>
</execution>
</executions>
</plugin>
<plugin>
<groupId>org.codehaus.mojo</groupId>
<artifactId>mrm-maven-plugin</artifactId>
<version>1.2.0</version>
<executions>
<execution>
<id>integration-tests</id>
<goals>
<goal>run</goal>
<goal>start</goal>
<goal>stop</goal>
</goals>
</execution>
</executions>
<configuration>
<repositories>
<mockRepo>
<source>src/it/mrm/repository</source>
</mockRepo>
<proxyRepo/>
</repositories>
</configuration>
</plugin>
</plugins>
</build>
Expand Down
File renamed without changes.
31 changes: 20 additions & 11 deletions src/it/settings.xml → src/it/mrm/settings.xml
Original file line number Diff line number Diff line change
Expand Up @@ -20,44 +20,53 @@ under the License.
-->

<settings>
<mirrors>
<mirrors>
<mirror>
<id>it-repo</id>
<name>RPM</name>
<url>@localRepositoryUrl@</url>
<id>mrm-maven-plugin</id>
<name>Mock Repository Manager</name>
<url>@mrm.repository.url@</url>
<mirrorOf>*</mirrorOf>
</mirror>
</mirrors>
<profiles>
<profile>
<id>it-repo</id>
<activation>
<activeByDefault>true</activeByDefault>
</activation>
<repositories>
<repository>
<id>local.central</id>
<url>@localRepositoryUrl@</url>
<id>snapshots</id>
<url>@mrm.repository.url@</url>
<releases>
<enabled>true</enabled>
<checksumPolicy>ignore</checksumPolicy>
<updatePolicy>never</updatePolicy>
</releases>
<snapshots>
<enabled>true</enabled>
<checksumPolicy>ignore</checksumPolicy>
<updatePolicy>always</updatePolicy>
</snapshots>
</repository>
</repositories>
<pluginRepositories>
<pluginRepository>
<id>local.central</id>
<url>@localRepositoryUrl@</url>
<id>snapshots</id>
<url>@mrm.repository.url@</url>
<releases>
<enabled>true</enabled>
<checksumPolicy>ignore</checksumPolicy>
<updatePolicy>never</updatePolicy>
</releases>
<snapshots>
<enabled>true</enabled>
<checksumPolicy>ignore</checksumPolicy>
<updatePolicy>always</updatePolicy>
</snapshots>
</pluginRepository>
</pluginRepositories>
</profile>
</profiles>
<activeProfiles>
<activeProfile>it-repo</activeProfile>
</activeProfiles>

</settings>
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
Original file line number Diff line number Diff line change
@@ -1,2 +1,3 @@
invoker.goals = clean package
invoker.buildResult = success
invoker.debug = true
File renamed without changes.
File renamed without changes.
File renamed without changes.
Original file line number Diff line number Diff line change
@@ -1,2 +1,3 @@
invoker.goals = clean package
invoker.buildResult = success
invoker.debug = true
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
Original file line number Diff line number Diff line change
@@ -1,2 +1,3 @@
invoker.goals = clean verify
invoker.buildResult = failure
invoker.debug = true
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
Original file line number Diff line number Diff line change
@@ -1 +1,2 @@
invoker.goals = clean verify
invoker.debug = true
7 changes: 0 additions & 7 deletions src/it/setup/invoker.properties

This file was deleted.