Skip to content

Commit

Permalink
[WIP] remove extension from IT, allow skipping main ITs
Browse files Browse the repository at this point in the history
  • Loading branch information
bmarwell committed Jul 20, 2023
1 parent c4f8270 commit 95b923d
Show file tree
Hide file tree
Showing 6 changed files with 150 additions and 7 deletions.
142 changes: 142 additions & 0 deletions liberty-maven-plugin-integration-tests/assembly-server/pom.xml
Original file line number Diff line number Diff line change
@@ -0,0 +1,142 @@
<?xml version="1.0" encoding="UTF-8"?>
<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">

<modelVersion>4.0.0</modelVersion>

<parent>
<groupId>io.openliberty.tools.it</groupId>
<artifactId>liberty-maven-plugin-integration-tests</artifactId>
<version>3.8.3-SNAPSHOT</version>
</parent>

<artifactId>assembly-server</artifactId>
<packaging>pom</packaging>

<properties>
<!-- Specify Liberty profile server installation directory -->
<liberty.install.dir>${libertyInstallDir}</liberty.install.dir>
</properties>

<build>
<pluginManagement>
<plugins>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-antrun-plugin</artifactId>
<version>3.1.0</version>
</plugin>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-install-plugin</artifactId>
<version>3.1.1</version>
</plugin>
<plugin>
<groupId>io.openliberty.tools</groupId>
<artifactId>liberty-maven-plugin</artifactId>
<version>${project.version}</version>
</plugin>
</plugins>
</pluginManagement>
<plugins>
<plugin>
<!-- install the liberty server zip the local maven repo. This is used
by the liberty-packaging-test and liberty-packaging-it tests -->
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-install-plugin</artifactId>
<executions>
<execution>
<id>install-liberty-to-repo</id>
<phase>compile</phase>
<goals>
<goal>install-file</goal>
</goals>
<configuration>
<file>${basedir}/target/liberty.zip</file>
<groupId>${project.groupId}</groupId>
<artifactId>${project.artifactId}</artifactId>
<version>${project.version}</version>
<packaging>zip</packaging>
</configuration>
</execution>
</executions>
</plugin>
</plugins>
</build>
<profiles>
<profile>
<id>offline-its</id>
<build>
<plugins>
<plugin>
<!-- zip up the liberty server to deploy it to the local maven repo
(next plugin) -->
<!-- I would expect the server is already available as a zip, but I
can't find it -->
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-antrun-plugin</artifactId>
<executions>
<execution>
<phase>generate-resources</phase>
<configuration>
<target>
<zip basedir="${liberty.install.dir}" destfile="${basedir}/target/liberty.zip"
excludes="usr/servers/**" />
</target>
</configuration>
<goals>
<goal>run</goal>
</goals>
</execution>
</executions>
</plugin>
</plugins>
</build>
</profile>
<profile>
<id>online-its</id>
<build>
<plugins>
<plugin>
<groupId>io.openliberty.tools</groupId>
<artifactId>liberty-maven-plugin</artifactId>
<executions>
<execution>
<id>downloading-wlp</id>
<phase>generate-resources</phase>
<goals>
<goal>status</goal>
</goals>
<configuration>
<assemblyArtifact>
<groupId>${runtimeGroupId}</groupId>
<artifactId>${runtimeArtifactId}</artifactId>
<version>${runtimeVersion}</version>
<type>zip</type>
</assemblyArtifact>
</configuration>
</execution>
</executions>
</plugin>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-antrun-plugin</artifactId>
<executions>
<execution>
<phase>process-resources</phase>
<configuration>
<target>
<zip basedir="${basedir}/target/liberty/wlp" destfile="${basedir}/target/liberty.zip" />
</target>
</configuration>
<goals>
<goal>run</goal>
</goals>
</execution>
</executions>
</plugin>
</plugins>
</build>
</profile>
</profiles>
</project>
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,12 @@
<version>${project.version}</version>
<type>maven-plugin</type>
</dependency>
<dependency>
<groupId>io.openliberty.tools.it</groupId>
<artifactId>assembly-server</artifactId>
<version>${project.version}</version>
<type>pom</type>
</dependency>
<dependency>
<groupId>org.apache.geronimo.specs</groupId>
<artifactId>geronimo-servlet_3.0_spec</artifactId>
Expand Down Expand Up @@ -75,7 +81,6 @@
<groupId>io.openliberty.tools</groupId>
<artifactId>liberty-maven-plugin</artifactId>
<version>${project.version}</version>
<extensions>true</extensions>
<configuration>
<stripVersion>true</stripVersion>
<assemblyArtifact>
Expand Down

This file was deleted.

This file was deleted.

1 change: 1 addition & 0 deletions liberty-maven-plugin-integration-tests/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,7 @@
<name>Liberty Maven Plugin :: ITs</name>

<modules>
<module>assembly-server</module>
<module>config-directory-it</module>
</modules>

Expand Down
1 change: 1 addition & 0 deletions liberty-maven-plugin/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -183,6 +183,7 @@
</profiles>
<streamLogs>true</streamLogs>
<mavenOpts>-Dfile.encoding=UTF-8</mavenOpts>
<skipInvocation>${skipPluginIts}</skipInvocation>
</configuration>
<executions>
<execution>
Expand Down

0 comments on commit 95b923d

Please sign in to comment.