|
|
2b958c |
From 2f414c5566febf44beb77c43340eafccad1547e2 Mon Sep 17 00:00:00 2001
|
|
|
2b958c |
From: Mikolaj Izdebski <mizdebsk@redhat.com>
|
|
|
2b958c |
Date: Tue, 17 Jul 2018 11:57:16 +0200
|
|
|
2b958c |
Subject: [PATCH] Remove dependency on junit-addons
|
|
|
2b958c |
|
|
|
2b958c |
---
|
|
|
2b958c |
pom.xml | 6 ------
|
|
|
2b958c |
.../apache/maven/reporting/AbstractMavenReportRenderer.java | 2 +-
|
|
|
2b958c |
.../maven/reporting/AbstractMavenReportRendererTest.java | 10 ++--------
|
|
|
2b958c |
3 files changed, 3 insertions(+), 15 deletions(-)
|
|
|
2b958c |
|
|
|
2b958c |
diff --git a/pom.xml b/pom.xml
|
|
|
2b958c |
index 239742e..dc75ecd 100644
|
|
|
2b958c |
--- a/pom.xml
|
|
|
2b958c |
+++ b/pom.xml
|
|
|
2b958c |
@@ -135,12 +135,6 @@
|
|
|
2b958c |
<version>3.8.2</version>
|
|
|
2b958c |
<scope>test</scope>
|
|
|
2b958c |
</dependency>
|
|
|
2b958c |
- <dependency>
|
|
|
2b958c |
- <groupId>junit-addons</groupId>
|
|
|
2b958c |
- <artifactId>junit-addons</artifactId>
|
|
|
2b958c |
- <version>1.4</version>
|
|
|
2b958c |
- <scope>test</scope>
|
|
|
2b958c |
- </dependency>
|
|
|
2b958c |
</dependencies>
|
|
|
2b958c |
|
|
|
2b958c |
<build>
|
|
|
2b958c |
diff --git a/src/main/java/org/apache/maven/reporting/AbstractMavenReportRenderer.java b/src/main/java/org/apache/maven/reporting/AbstractMavenReportRenderer.java
|
|
|
2b958c |
index 6f954ae..c11acd3 100644
|
|
|
2b958c |
--- a/src/main/java/org/apache/maven/reporting/AbstractMavenReportRenderer.java
|
|
|
2b958c |
+++ b/src/main/java/org/apache/maven/reporting/AbstractMavenReportRenderer.java
|
|
|
2b958c |
@@ -597,7 +597,7 @@ public abstract class AbstractMavenReportRenderer
|
|
|
2b958c |
* @param text a text with or without the pattern {text, url}
|
|
|
2b958c |
* @return a map of text/href
|
|
|
2b958c |
*/
|
|
|
2b958c |
- private static List<String> applyPattern( String text )
|
|
|
2b958c |
+ static List<String> applyPattern( String text )
|
|
|
2b958c |
{
|
|
|
2b958c |
if ( StringUtils.isEmpty( text ) )
|
|
|
2b958c |
{
|
|
|
2b958c |
diff --git a/src/test/java/org/apache/maven/reporting/AbstractMavenReportRendererTest.java b/src/test/java/org/apache/maven/reporting/AbstractMavenReportRendererTest.java
|
|
|
2b958c |
index cdb9299..e8dce8f 100644
|
|
|
2b958c |
--- a/src/test/java/org/apache/maven/reporting/AbstractMavenReportRendererTest.java
|
|
|
2b958c |
+++ b/src/test/java/org/apache/maven/reporting/AbstractMavenReportRendererTest.java
|
|
|
2b958c |
@@ -24,7 +24,8 @@ import java.util.List;
|
|
|
2b958c |
|
|
|
2b958c |
import junit.framework.Assert;
|
|
|
2b958c |
import junit.framework.TestCase;
|
|
|
2b958c |
-import junitx.util.PrivateAccessor;
|
|
|
2b958c |
+
|
|
|
2b958c |
+import static org.apache.maven.reporting.AbstractMavenReportRenderer.applyPattern;
|
|
|
2b958c |
|
|
|
2b958c |
/**
|
|
|
2b958c |
* Test case for some public method in AbstractMavenReportRenderer.
|
|
|
2b958c |
@@ -32,13 +33,6 @@ import junitx.util.PrivateAccessor;
|
|
|
2b958c |
public class AbstractMavenReportRendererTest
|
|
|
2b958c |
extends TestCase
|
|
|
2b958c |
{
|
|
|
2b958c |
- private static List<String> applyPattern( String pattern )
|
|
|
2b958c |
- throws Throwable
|
|
|
2b958c |
- {
|
|
|
2b958c |
- return (List<String>) PrivateAccessor.invoke( AbstractMavenReportRenderer.class, "applyPattern",
|
|
|
2b958c |
- new Class[] { String.class }, new Object[] { pattern } );
|
|
|
2b958c |
- }
|
|
|
2b958c |
-
|
|
|
2b958c |
private static void checkPattern( String pattern, String[] expectedResult ) throws Throwable
|
|
|
2b958c |
{
|
|
|
2b958c |
List<String> result = applyPattern( pattern );
|
|
|
2b958c |
--
|
|
|
2b958c |
2.14.3
|
|
|
2b958c |
|