From 3064f6c541c28c33cf452150d6898adfe1ab7579 Mon Sep 17 00:00:00 2001 From: Slawomir Jaranowski Date: Mon, 1 Dec 2025 19:29:10 +0100 Subject: [PATCH] Add IT for #444 issue Try to reproduce reported issue #444 As we don't have an IT with includes and filtering add one --- src/it/gh-444/pom.xml | 59 +++++++++++++++++++++ src/it/gh-444/src/main/java/test.properties | 19 +++++++ src/it/gh-444/src/main/java/test.txt | 18 +++++++ src/it/gh-444/src/main/java/test.xml | 22 ++++++++ src/it/gh-444/verify.groovy | 28 ++++++++++ 5 files changed, 146 insertions(+) create mode 100644 src/it/gh-444/pom.xml create mode 100644 src/it/gh-444/src/main/java/test.properties create mode 100644 src/it/gh-444/src/main/java/test.txt create mode 100644 src/it/gh-444/src/main/java/test.xml create mode 100644 src/it/gh-444/verify.groovy diff --git a/src/it/gh-444/pom.xml b/src/it/gh-444/pom.xml new file mode 100644 index 0000000..10f4f0c --- /dev/null +++ b/src/it/gh-444/pom.xml @@ -0,0 +1,59 @@ + + + + + 4.0.0 + + org.apache.maven.plugins + gh-444 + jar + 1.0-SNAPSHOT + + + cacheNameValue + + + + + + src/main/java + true + + **/*.properties + + + + src/main/java + + **/*.xml + + + + + + + + maven-resources-plugin + @project.version@ + + + + + diff --git a/src/it/gh-444/src/main/java/test.properties b/src/it/gh-444/src/main/java/test.properties new file mode 100644 index 0000000..c8895bc --- /dev/null +++ b/src/it/gh-444/src/main/java/test.properties @@ -0,0 +1,19 @@ +# 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.version=${project.version} +loginSession.refNoCl_cache=@cacheName@ diff --git a/src/it/gh-444/src/main/java/test.txt b/src/it/gh-444/src/main/java/test.txt new file mode 100644 index 0000000..e11921f --- /dev/null +++ b/src/it/gh-444/src/main/java/test.txt @@ -0,0 +1,18 @@ +# 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. + +Test text file. diff --git a/src/it/gh-444/src/main/java/test.xml b/src/it/gh-444/src/main/java/test.xml new file mode 100644 index 0000000..8fe9f4c --- /dev/null +++ b/src/it/gh-444/src/main/java/test.xml @@ -0,0 +1,22 @@ + + + + ${project.version} + diff --git a/src/it/gh-444/verify.groovy b/src/it/gh-444/verify.groovy new file mode 100644 index 0000000..74e26cc --- /dev/null +++ b/src/it/gh-444/verify.groovy @@ -0,0 +1,28 @@ +/* + * 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. + */ + +def propertiesFile = new File(basedir, 'target/classes/test.properties').text +assert propertiesFile.contains('project.version=1.0-SNAPSHOT') +assert propertiesFile.contains('loginSession.refNoCl_cache=cacheNameValue') + +def xmlFile = new File(basedir, 'target/classes/test.xml').text +assert xmlFile.contains('${project.version}') + +def textFile = new File(basedir, 'target/classes/test.txt') +assert !textFile.exists()