Skip to content

Commit

Permalink
(v2.2.x): Bump org.apache.maven.shared:maven-filtering from 3.2.0 to …
Browse files Browse the repository at this point in the history
…3.3.1 (#681)

* (v2.2.x): Bump org.apache.maven.shared:maven-filtering

Bumps [org.apache.maven.shared:maven-filtering](https://github.com/apache/maven-filtering) from 3.2.0 to 3.3.1.
- [Release notes](https://github.com/apache/maven-filtering/releases)
- [Commits](apache/maven-filtering@maven-filtering-3.2.0...maven-filtering-3.3.1)

---
updated-dependencies:
- dependency-name: org.apache.maven.shared:maven-filtering
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <[email protected]>

* Fix test code

---------

Signed-off-by: dependabot[bot] <[email protected]>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
  • Loading branch information
abelsromero and dependabot[bot] authored Dec 26, 2023
1 parent 98f375f commit 2a55501
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 14 deletions.
2 changes: 1 addition & 1 deletion pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -80,7 +80,7 @@
<maven.jacoco.plugin.version>0.8.10</maven.jacoco.plugin.version>
<maven.plugin.plugin.version>3.9.0</maven.plugin.plugin.version>
<maven.project.version>3.8.5</maven.project.version>
<maven.filtering.version>3.2.0</maven.filtering.version>
<maven.filtering.version>3.3.1</maven.filtering.version>
<plexus.utils.version>3.5.1</plexus.utils.version>
<plexus.component.metadata.version>2.1.1</plexus.component.metadata.version>
<netty.version>4.1.104.Final</netty.version>
Expand Down
17 changes: 4 additions & 13 deletions src/test/java/org/asciidoctor/maven/TestUtils.java
Original file line number Diff line number Diff line change
Expand Up @@ -7,8 +7,9 @@
import org.apache.maven.project.MavenProject;
import org.apache.maven.shared.filtering.DefaultMavenFileFilter;
import org.apache.maven.shared.filtering.DefaultMavenResourcesFiltering;
import org.apache.maven.shared.filtering.MavenFileFilter;
import org.apache.maven.shared.filtering.MavenResourcesFiltering;
import org.asciidoctor.maven.log.LogHandler;
import org.codehaus.plexus.logging.console.ConsoleLogger;
import org.mockito.Mockito;
import org.sonatype.plexus.build.incremental.BuildContext;
import org.sonatype.plexus.build.incremental.DefaultBuildContext;
Expand Down Expand Up @@ -66,17 +67,8 @@ private static <T> T mockAsciidoctorMojo(Class<T> clazz, Map<String, String> mav
}

final BuildContext buildContext = new DefaultBuildContext();

final DefaultMavenFileFilter mavenFileFilter = new DefaultMavenFileFilter();
final ConsoleLogger plexusLogger = new ConsoleLogger();
mavenFileFilter.enableLogging(plexusLogger);
setVariableValueInObject(mavenFileFilter, "buildContext", buildContext);

final DefaultMavenResourcesFiltering resourceFilter = new DefaultMavenResourcesFiltering();
setVariableValueInObject(resourceFilter, "mavenFileFilter", mavenFileFilter);
setVariableValueInObject(resourceFilter, "buildContext", buildContext);
resourceFilter.initialize();
resourceFilter.enableLogging(plexusLogger);
final MavenFileFilter mavenFileFilter = new DefaultMavenFileFilter(buildContext);
final MavenResourcesFiltering resourceFilter = new DefaultMavenResourcesFiltering(mavenFileFilter, buildContext);

final AsciidoctorMojo mojo = (AsciidoctorMojo) clazz.getConstructor(new Class[]{}).newInstance();
setVariableValueInObject(mojo, "log", new SystemStreamLog());
Expand Down Expand Up @@ -160,5 +152,4 @@ public static List<Resource> excludeAll() {
return singletonList(new ResourceBuilder().directory(".").excludes("**/**").build());
}
}

}

0 comments on commit 2a55501

Please sign in to comment.