From 7ce2a93f3a0686a68a59187bdb5c034e9150417f Mon Sep 17 00:00:00 2001 From: zentol Date: Mon, 24 Jul 2017 14:14:19 +0200 Subject: [PATCH] [FLINK-7254] [java8] Properly activate checkstyle for flink-java8 --- flink-java8/pom.xml | 4 ---- .../api/java/type/lambdas/LambdaExtractionTest.java | 10 +++++----- .../test/java/org/apache/flink/cep/CEPLambdaTest.java | 1 - flink-java8/src/test/resources/log4j-test.properties | 2 +- 4 files changed, 6 insertions(+), 11 deletions(-) diff --git a/flink-java8/pom.xml b/flink-java8/pom.xml index fb7da026583f4..a3fcea5fea36c 100644 --- a/flink-java8/pom.xml +++ b/flink-java8/pom.xml @@ -35,10 +35,6 @@ under the License. jar - - true - - diff --git a/flink-java8/src/test/java/org/apache/flink/api/java/type/lambdas/LambdaExtractionTest.java b/flink-java8/src/test/java/org/apache/flink/api/java/type/lambdas/LambdaExtractionTest.java index 175c6feab7d9b..d862f4724fe8a 100644 --- a/flink-java8/src/test/java/org/apache/flink/api/java/type/lambdas/LambdaExtractionTest.java +++ b/flink-java8/src/test/java/org/apache/flink/api/java/type/lambdas/LambdaExtractionTest.java @@ -327,7 +327,7 @@ public void testConstructorMethodRef() { Assert.assertEquals(BasicTypeInfo.INT_TYPE_INFO, ti); } - public interface InterfaceWithDefaultMethod { + private interface InterfaceWithDefaultMethod { void samMethod(); default void defaultMethod() { @@ -342,7 +342,7 @@ public void testSamMethodExtractionInterfaceWithDefaultMethod() { assertEquals("samMethod", sam.getName()); } - public interface InterfaceWithMultipleMethods { + private interface InterfaceWithMultipleMethods { void firstMethod(); void secondMethod(); @@ -353,10 +353,10 @@ public void getSingleAbstractMethodMultipleMethods() throws Exception { TypeExtractionUtils.getSingleAbstractMethod(InterfaceWithMultipleMethods.class); } - public interface InterfaceWithoutAbstractMethod { + private interface InterfaceWithoutAbstractMethod { default void defaultMethod() { - }; + } } @Test(expected = InvalidTypesException.class) @@ -364,7 +364,7 @@ public void getSingleAbstractMethodNoAbstractMethods() throws Exception { TypeExtractionUtils.getSingleAbstractMethod(InterfaceWithoutAbstractMethod.class); } - public abstract class AbstractClassWithSingleAbstractMethod { + private abstract class AbstractClassWithSingleAbstractMethod { public abstract void defaultMethod(); } diff --git a/flink-java8/src/test/java/org/apache/flink/cep/CEPLambdaTest.java b/flink-java8/src/test/java/org/apache/flink/cep/CEPLambdaTest.java index 37bf872f6ee00..7cbdf6a8a0657 100644 --- a/flink-java8/src/test/java/org/apache/flink/cep/CEPLambdaTest.java +++ b/flink-java8/src/test/java/org/apache/flink/cep/CEPLambdaTest.java @@ -27,7 +27,6 @@ import org.apache.flink.util.Collector; import org.apache.flink.util.TestLogger; -import org.junit.Ignore; import org.junit.Test; import java.util.List; diff --git a/flink-java8/src/test/resources/log4j-test.properties b/flink-java8/src/test/resources/log4j-test.properties index 2fb9345dc1d7b..c977d4c3ae39f 100644 --- a/flink-java8/src/test/resources/log4j-test.properties +++ b/flink-java8/src/test/resources/log4j-test.properties @@ -16,4 +16,4 @@ # limitations under the License. ################################################################################ -log4j.rootLogger=OFF \ No newline at end of file +log4j.rootLogger=OFF