From be6939bd97e23f7bda3c9c540dd61a5824e7347f Mon Sep 17 00:00:00 2001 From: anton-k11 Date: Thu, 22 Sep 2016 00:04:53 +0300 Subject: [PATCH] Removing comments, reformatting. --- core-java-9/pom.xml | 11 +---------- .../baeldung/java9/MultiResultionImageTest.java | 1 - .../com/baeldung/java9/OptionalToStreamTest.java | 12 ++++++------ .../java/com/baeldung/java9/SetExamplesTest.java | 15 +++++++-------- 4 files changed, 14 insertions(+), 25 deletions(-) diff --git a/core-java-9/pom.xml b/core-java-9/pom.xml index b29838d283..844ad6a782 100644 --- a/core-java-9/pom.xml +++ b/core-java-9/pom.xml @@ -60,12 +60,8 @@ 1.9 1.9 - true - - @@ -85,12 +81,7 @@ - - 3.6-jigsaw-SNAPSHOT - - + 3.6-jigsaw-SNAPSHOT 2.19.1 diff --git a/core-java-9/src/test/java/com/baeldung/java9/MultiResultionImageTest.java b/core-java-9/src/test/java/com/baeldung/java9/MultiResultionImageTest.java index d6c16b91bc..0805e06794 100644 --- a/core-java-9/src/test/java/com/baeldung/java9/MultiResultionImageTest.java +++ b/core-java-9/src/test/java/com/baeldung/java9/MultiResultionImageTest.java @@ -1,6 +1,5 @@ package com.baeldung.java9; -import static org.junit.Assert.assertTrue; import static org.junit.Assert.assertEquals; import static org.junit.Assert.assertSame; diff --git a/core-java-9/src/test/java/com/baeldung/java9/OptionalToStreamTest.java b/core-java-9/src/test/java/com/baeldung/java9/OptionalToStreamTest.java index 966c03fe17..56b4bb7b8c 100644 --- a/core-java-9/src/test/java/com/baeldung/java9/OptionalToStreamTest.java +++ b/core-java-9/src/test/java/com/baeldung/java9/OptionalToStreamTest.java @@ -7,15 +7,15 @@ import org.junit.Test; import static org.junit.Assert.assertEquals; public class OptionalToStreamTest { - + @Test - public void testOptionalToStream(){ + public void testOptionalToStream() { Optional op = Optional.ofNullable("String value"); Stream strOptionalStream = op.stream(); - Stream filteredStream = strOptionalStream.filter( - (str) -> { return str != null && str.startsWith("String"); } - ); + Stream filteredStream = strOptionalStream.filter((str) -> { + return str != null && str.startsWith("String"); + }); assertEquals(1, filteredStream.count()); - + } } diff --git a/core-java-9/src/test/java/com/baeldung/java9/SetExamplesTest.java b/core-java-9/src/test/java/com/baeldung/java9/SetExamplesTest.java index c534ba9d47..0f8db83d9c 100644 --- a/core-java-9/src/test/java/com/baeldung/java9/SetExamplesTest.java +++ b/core-java-9/src/test/java/com/baeldung/java9/SetExamplesTest.java @@ -1,6 +1,5 @@ package com.baeldung.java9; - import java.util.Set; import org.junit.Test; @@ -9,18 +8,18 @@ import static org.junit.Assert.assertEquals; public class SetExamplesTest { @Test - public void testUnmutableSet(){ + public void testUnmutableSet() { Set strKeySet = Set.of("key1", "key2", "key3"); - try{ + try { strKeySet.add("newKey"); - }catch(UnsupportedOperationException uoe){ + } catch (UnsupportedOperationException uoe) { } - assertEquals(strKeySet.size(), 3); + assertEquals(strKeySet.size(), 3); } - + @Test - public void testArrayToSet(){ - Integer [] intArray = new Integer[]{1,2,3,4,5,6,7,8,9,0}; + public void testArrayToSet() { + Integer[] intArray = new Integer[] { 1, 2, 3, 4, 5, 6, 7, 8, 9, 0 }; Set intSet = Set.of(intArray); assertEquals(intSet.size(), intArray.length); }