Skip to content

Commit 05f542a

Browse files
github-actionsgithub-actions
github-actions
authored and
github-actions
committed
Formatted with Google Java Formatter
1 parent 82c9ff1 commit 05f542a

16 files changed

+34
-47
lines changed
Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,3 @@
11
package com.examplehub.basics.system;
22

3-
public class FileSeparatorTest {
4-
}
3+
public class FileSeparatorTest {}
Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,3 @@
11
package com.examplehub.basics.time;
22

3-
public class CalendarExample {
4-
}
3+
public class CalendarExample {}
Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,3 @@
11
package com.examplehub.basics.time;
22

3-
public class DateExample {
4-
}
3+
public class DateExample {}
Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,3 @@
11
package com.examplehub.basics.time;
22

3-
public class GetTime {
4-
}
3+
public class GetTime {}
Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,3 @@
11
package com.examplehub.basics.time;
22

3-
public class InstantExample {
4-
}
3+
public class InstantExample {}
Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,3 @@
11
package com.examplehub.basics.time;
22

3-
public class LocalDateTimeExample {
4-
5-
}
3+
public class LocalDateTimeExample {}

src/test/java/com/examplehub/basics/ints/IntOperationTest.java

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,6 @@
33
import static org.junit.jupiter.api.Assertions.*;
44

55
import org.junit.jupiter.api.Test;
6-
import org.junit.jupiter.api.function.Executable;
76

87
class IntOperationTest {
98
@Test
@@ -20,9 +19,11 @@ void testDivide() {
2019
assertEquals(2, 7 / 3);
2120
assertEquals(164, 12345 / 75);
2221

23-
assertThrows(ArithmeticException.class, () -> {
24-
int division = 10 / 0;
25-
});
22+
assertThrows(
23+
ArithmeticException.class,
24+
() -> {
25+
int division = 10 / 0;
26+
});
2627
}
2728

2829
@Test
Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,22 +1,22 @@
11
package com.examplehub.basics.system;
22

3+
import static org.junit.jupiter.api.Assertions.*;
4+
5+
import java.io.File;
36
import org.junit.jupiter.api.Test;
47
import org.junit.jupiter.api.condition.EnabledOnOs;
58
import org.junit.jupiter.api.condition.OS;
69

7-
import java.io.File;
8-
9-
import static org.junit.jupiter.api.Assertions.*;
10-
1110
class FileSeparatorTestTest {
1211
@Test
1312
@EnabledOnOs({OS.LINUX, OS.MAC, OS.MAC})
1413
void testOnUnixLike() {
1514
assertEquals("/", File.separator);
1615
}
16+
1717
@Test
1818
@EnabledOnOs(OS.WINDOWS)
1919
void testOnWindows() {
2020
assertEquals("\\", File.separator);
2121
}
22-
}
22+
}

src/test/java/com/examplehub/basics/time/CalendarExampleTest.java

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,8 @@
11
package com.examplehub.basics.time;
22

3-
import org.junit.jupiter.api.Test;
4-
53
import java.text.SimpleDateFormat;
64
import java.util.Calendar;
5+
import org.junit.jupiter.api.Test;
76

87
class CalendarExampleTest {
98
@Test
@@ -33,4 +32,4 @@ void testSetCustomTime() {
3332
calendar.set(Calendar.SECOND, 59);
3433
System.out.println(new SimpleDateFormat("yyyy-MM-dd HH:mm:ss").format(calendar.getTime()));
3534
}
36-
}
35+
}

src/test/java/com/examplehub/basics/time/DateExampleTest.java

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,8 @@
11
package com.examplehub.basics.time;
22

3-
import org.junit.jupiter.api.Test;
4-
53
import java.text.SimpleDateFormat;
64
import java.util.Date;
5+
import org.junit.jupiter.api.Test;
76

87
class DateExampleTest {
98
@Test
@@ -22,4 +21,4 @@ void testSimpleDateForMate() {
2221
SimpleDateFormat format = new SimpleDateFormat("yyyy-MM-dd HH:mm:ss");
2322
System.out.println(format.format(new Date()));
2423
}
25-
}
24+
}

src/test/java/com/examplehub/basics/time/GetTimeTest.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,4 +7,4 @@ class GetTimeTest {
77
void test() {
88
System.out.println(System.currentTimeMillis());
99
}
10-
}
10+
}
Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,9 @@
11
package com.examplehub.basics.time;
22

3-
import org.junit.jupiter.api.Test;
3+
import static org.junit.jupiter.api.Assertions.*;
44

55
import java.time.Instant;
6-
7-
import static org.junit.jupiter.api.Assertions.*;
6+
import org.junit.jupiter.api.Test;
87

98
class InstantExampleTest {
109
@Test
@@ -14,4 +13,4 @@ void test() {
1413
System.out.println(now.toEpochMilli());
1514
System.out.println(now.getEpochSecond());
1615
}
17-
}
16+
}

src/test/java/com/examplehub/basics/time/LocalDateTimeExampleTest.java

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,9 @@
11
package com.examplehub.basics.time;
22

3-
import org.junit.jupiter.api.Test;
4-
53
import java.time.LocalDate;
64
import java.time.LocalDateTime;
75
import java.time.LocalTime;
6+
import org.junit.jupiter.api.Test;
87

98
class LocalDateTimeExampleTest {
109
@Test
@@ -38,4 +37,4 @@ void test3() {
3837
System.out.println(dt2);
3938
System.out.println(dt3);
4039
}
41-
}
40+
}

src/test/java/com/examplehub/basics/utils/MathUtilsExampleTest.java

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,6 @@
44

55
import org.junit.jupiter.api.Test;
66
import org.junit.jupiter.params.ParameterizedTest;
7-
import org.junit.jupiter.params.provider.ArgumentsSource;
87
import org.junit.jupiter.params.provider.ValueSource;
98

109
class MathUtilsExampleTest {

src/test/java/com/examplehub/sorts/BubbleSortTest.java

Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,15 +1,14 @@
11
package com.examplehub.sorts;
22

3+
import static org.junit.jupiter.api.Assertions.assertTrue;
4+
35
import com.examplehub.domain.Student;
46
import com.examplehub.utils.RandomUtils;
57
import com.examplehub.utils.SortUtils;
8+
import java.util.Arrays;
69
import org.junit.jupiter.api.BeforeEach;
710
import org.junit.jupiter.api.Test;
811

9-
import java.util.Arrays;
10-
11-
import static org.junit.jupiter.api.Assertions.assertTrue;
12-
1312
class BubbleSortTest {
1413

1514
private Sort sort;

src/test/java/com/examplehub/utils/StringUtilsTest.java

Lines changed: 5 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -2,15 +2,13 @@
22

33
import static org.junit.jupiter.api.Assertions.*;
44

5-
import org.junit.jupiter.api.Disabled;
5+
import java.util.List;
66
import org.junit.jupiter.api.Test;
77
import org.junit.jupiter.params.ParameterizedTest;
88
import org.junit.jupiter.params.provider.Arguments;
99
import org.junit.jupiter.params.provider.CsvSource;
1010
import org.junit.jupiter.params.provider.MethodSource;
1111

12-
import java.util.List;
13-
1412
class StringUtilsTest {
1513
@Test
1614
void testBytesToString() {
@@ -31,9 +29,10 @@ void testCapitalize(String input, String excepted) {
3129
}
3230

3331
static List<Arguments> testCapitalize() {
34-
return List.of(Arguments.arguments("abc", "Abc"), //
35-
Arguments.arguments("APPLE", "Apple"), //
36-
Arguments.arguments("gooD", "Good"));
32+
return List.of(
33+
Arguments.arguments("abc", "Abc"), //
34+
Arguments.arguments("APPLE", "Apple"), //
35+
Arguments.arguments("gooD", "Good"));
3736
}
3837

3938
@ParameterizedTest

0 commit comments

Comments
 (0)