| <?xml version="1.0" encoding="UTF-8"?> |
| |
| <!-- |
| Licensed to the Apache Software Foundation (ASF) under one |
| or more contributor license agreements. See the NOTICE file |
| distributed with this work for additional information |
| regarding copyright ownership. The ASF licenses this file |
| to you under the Apache License, Version 2.0 (the |
| "License"); you may not use this file except in compliance |
| with the License. You may obtain a copy of the License at |
| |
| http://www.apache.org/licenses/LICENSE-2.0 |
| |
| Unless required by applicable law or agreed to in writing, |
| software distributed under the License is distributed on an |
| "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY |
| KIND, either express or implied. See the License for the |
| specific language governing permissions and limitations |
| under the License. |
| --> |
| |
| <project> |
| <modelVersion>4.0.0</modelVersion> |
| |
| <groupId>org.apache.maven.its.mng5418</groupId> |
| <artifactId>parent</artifactId> |
| <version>0.1</version> |
| <packaging>pom</packaging> |
| |
| <name>Maven Integration Test :: MNG-5418</name> |
| <description> |
| Test that the file-based profile activator resolves file path with project properties. |
| </description> |
| |
| |
| <properties> |
| <site.base.path>${basedir}</site.base.path> |
| <site.final.path>${site.base.path}/sub1</site.final.path> |
| <site.final.file>${site.base.path}/sub1/foo.txt</site.final.file> |
| <site.final.path.not>${site.base.path}/sub2</site.final.path.not> |
| </properties> |
| |
| <profiles> |
| <profile> |
| <id>path-1</id> |
| <activation> |
| <file> |
| <exists>${site.final.path}</exists> |
| </file> |
| </activation> |
| <build> |
| <plugins> |
| <plugin> |
| <groupId>org.apache.maven.its.plugins</groupId> |
| <artifactId>maven-it-plugin-log-file</artifactId> |
| <version>2.1-SNAPSHOT</version> |
| <executions> |
| <execution> |
| <id>test-1</id> |
| <phase>validate</phase> |
| <configuration> |
| <logFile>target/path1.txt</logFile> |
| </configuration> |
| <goals> |
| <goal>reset</goal> |
| </goals> |
| </execution> |
| </executions> |
| </plugin> |
| </plugins> |
| </build> |
| </profile> |
| <profile> |
| <id>file-1</id> |
| <activation> |
| <file> |
| <exists>${site.final.file}</exists> |
| </file> |
| </activation> |
| <build> |
| <plugins> |
| <plugin> |
| <groupId>org.apache.maven.its.plugins</groupId> |
| <artifactId>maven-it-plugin-log-file</artifactId> |
| <version>2.1-SNAPSHOT</version> |
| <executions> |
| <execution> |
| <id>test-2</id> |
| <phase>validate</phase> |
| <configuration> |
| <logFile>target/file1.txt</logFile> |
| </configuration> |
| <goals> |
| <goal>reset</goal> |
| </goals> |
| </execution> |
| </executions> |
| </plugin> |
| </plugins> |
| </build> |
| </profile> |
| <profile> |
| <id>missing-1</id> |
| <activation> |
| <file> |
| <missing>${site.final.path.not}</missing> |
| </file> |
| </activation> |
| <build> |
| <plugins> |
| <plugin> |
| <groupId>org.apache.maven.its.plugins</groupId> |
| <artifactId>maven-it-plugin-log-file</artifactId> |
| <version>2.1-SNAPSHOT</version> |
| <executions> |
| <execution> |
| <id>test-3</id> |
| <phase>validate</phase> |
| <configuration> |
| <logFile>target/missing1.txt</logFile> |
| </configuration> |
| <goals> |
| <goal>reset</goal> |
| </goals> |
| </execution> |
| </executions> |
| </plugin> |
| </plugins> |
| </build> |
| </profile> |
| <profile> |
| <id>missing-2</id> |
| <activation> |
| <file> |
| <exists>${site.final.path.not}</exists> |
| </file> |
| </activation> |
| <build> |
| <plugins> |
| <plugin> |
| <groupId>org.apache.maven.its.plugins</groupId> |
| <artifactId>maven-it-plugin-log-file</artifactId> |
| <version>2.1-SNAPSHOT</version> |
| <executions> |
| <execution> |
| <id>test-4</id> |
| <phase>validate</phase> |
| <configuration> |
| <logFile>target/missing2.txt</logFile> |
| </configuration> |
| <goals> |
| <goal>reset</goal> |
| </goals> |
| </execution> |
| </executions> |
| </plugin> |
| </plugins> |
| </build> |
| </profile> |
| </profiles> |
| </project> |