Skip to content

Commit 3d737b0

Browse files
committed
Use JUnit 5 convention for class visibility
1 parent 48afb43 commit 3d737b0

File tree

99 files changed

+120
-109
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

99 files changed

+120
-109
lines changed

src/test/java/org/apache/commons/collections4/ArrayUtilsTest.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@
2222

2323
import org.junit.jupiter.api.Test;
2424

25-
public class ArrayUtilsTest {
25+
class ArrayUtilsTest {
2626

2727
@Test
2828
void testContains() {

src/test/java/org/apache/commons/collections4/BagUtilsTest.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -37,7 +37,7 @@
3737
/**
3838
* Tests for BagUtils factory methods.
3939
*/
40-
public class BagUtilsTest {
40+
class BagUtilsTest {
4141

4242
protected Predicate<Object> truePredicate = TruePredicate.truePredicate();
4343
protected Transformer<Object, Object> nopTransformer = TransformerUtils.nopTransformer();

src/test/java/org/apache/commons/collections4/ClosureUtilsTest.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -38,7 +38,7 @@
3838
/**
3939
* Tests the ClosureUtils class.
4040
*/
41-
public class ClosureUtilsTest {
41+
class ClosureUtilsTest {
4242

4343
static class MockClosure<T> implements Closure<T> {
4444
int count;

src/test/java/org/apache/commons/collections4/CollectionUtilsTest.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -64,7 +64,7 @@
6464
* Tests for CollectionUtils.
6565
*/
6666
@SuppressWarnings("boxing")
67-
public class CollectionUtilsTest extends MockTestCase {
67+
class CollectionUtilsTest extends MockTestCase {
6868

6969
private static final Predicate<Number> EQUALS_TWO = input -> input.intValue() == 2;
7070

src/test/java/org/apache/commons/collections4/ComparatorUtilsTest.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -27,7 +27,7 @@
2727
/**
2828
* Tests ComparatorUtils.
2929
*/
30-
public class ComparatorUtilsTest {
30+
class ComparatorUtilsTest {
3131

3232
@Test
3333
void testBooleanComparator() {

src/test/java/org/apache/commons/collections4/EnumerationUtilsTest.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -36,7 +36,7 @@
3636
/**
3737
* Tests EnumerationUtils.
3838
*/
39-
public class EnumerationUtilsTest {
39+
class EnumerationUtilsTest {
4040

4141
public static final String TO_LIST_FIXTURE = "this is a test";
4242

src/test/java/org/apache/commons/collections4/FactoryUtilsTest.java

Lines changed: 13 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -39,20 +39,25 @@
3939
public class FactoryUtilsTest {
4040

4141
public static class Mock1 {
42+
4243
private final int iVal;
44+
4345
public Mock1(final int val) {
4446
iVal = val;
4547
}
48+
4649
public Mock1(final Mock1 mock) {
4750
iVal = mock.iVal;
4851
}
52+
4953
@Override
5054
public boolean equals(final Object obj) {
5155
if (obj instanceof Mock1 && iVal == ((Mock1) obj).iVal) {
5256
return true;
5357
}
5458
return false;
5559
}
60+
5661
@Override
5762
public int hashCode() { // please Findbugs
5863
return super.hashCode();
@@ -65,29 +70,35 @@ public static class Mock2 implements Serializable {
6570
*/
6671
private static final long serialVersionUID = 4899282162482588924L;
6772
private final Object iVal;
68-
public Mock2(final Object val) {
73+
74+
Mock2(final Object val) {
6975
iVal = val;
7076
}
77+
7178
@Override
7279
public boolean equals(final Object obj) {
7380
if (obj instanceof Mock2 && iVal == ((Mock2) obj).iVal) {
7481
return true;
7582
}
7683
return false;
7784
}
85+
7886
@Override
7987
public int hashCode() { // please Findbugs
8088
return super.hashCode();
8189
}
8290
}
8391

8492
public static class Mock3 {
93+
8594
private static int cCounter;
8695
private final int iVal;
96+
8797
public Mock3() {
8898
iVal = cCounter++;
8999
}
90-
public int getValue() {
100+
101+
int getValue() {
91102
return iVal;
92103
}
93104
}

src/test/java/org/apache/commons/collections4/FluentIterableTest.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -40,7 +40,7 @@
4040
/**
4141
* Tests for FluentIterable.
4242
*/
43-
public class FluentIterableTest {
43+
class FluentIterableTest {
4444

4545
private static final Predicate<Number> EVEN = input -> input.intValue() % 2 == 0;
4646

src/test/java/org/apache/commons/collections4/IterableUtilsTest.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -46,7 +46,7 @@
4646
/**
4747
* Tests for IterableUtils.
4848
*/
49-
public class IterableUtilsTest {
49+
class IterableUtilsTest {
5050

5151
private static final Predicate<Number> EQUALS_TWO = input -> input.intValue() == 2;
5252

src/test/java/org/apache/commons/collections4/IteratorUtilsTest.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -66,7 +66,7 @@
6666
/**
6767
* Tests for IteratorUtils.
6868
*/
69-
public class IteratorUtilsTest {
69+
class IteratorUtilsTest {
7070

7171
/**
7272
* Collection of {@link Integer}s

0 commit comments

Comments
 (0)