Skip to content

Commit efec60f

Browse files
committed
HADOOP-19427. Fix CheckStyle Issue.
1 parent 199e549 commit efec60f

File tree

4 files changed

+18
-17
lines changed

4 files changed

+18
-17
lines changed

hadoop-tools/hadoop-compat-bench/src/test/java/org/apache/hadoop/fs/compat/common/TestHdfsCompatDefaultSuites.java

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -17,11 +17,12 @@
1717
*/
1818
package org.apache.hadoop.fs.compat.common;
1919

20+
import static org.junit.jupiter.api.Assertions.assertEquals;
21+
2022
import org.apache.hadoop.fs.compat.HdfsCompatTool;
2123
import org.apache.hadoop.fs.compat.hdfs.HdfsCompatMiniCluster;
2224
import org.apache.hadoop.fs.compat.hdfs.HdfsCompatTestCommand;
2325
import org.apache.hadoop.conf.Configuration;
24-
import org.junit.jupiter.api.Assertions;
2526
import org.junit.jupiter.api.Test;
2627

2728
public class TestHdfsCompatDefaultSuites {
@@ -35,7 +36,7 @@ public void testSuiteAll() throws Exception {
3536
HdfsCompatCommand cmd = new HdfsCompatTestCommand(uri, "ALL", conf);
3637
cmd.initialize();
3738
HdfsCompatReport report = cmd.apply();
38-
Assertions.assertEquals(0, report.getFailedCase().size());
39+
assertEquals(0, report.getFailedCase().size());
3940
new HdfsCompatTool(conf).printReport(report, System.out);
4041
} finally {
4142
cluster.shutdown();
@@ -52,7 +53,7 @@ public void testSuiteTpcds() throws Exception {
5253
HdfsCompatCommand cmd = new HdfsCompatTestCommand(uri, "TPCDS", conf);
5354
cmd.initialize();
5455
HdfsCompatReport report = cmd.apply();
55-
Assertions.assertEquals(0, report.getFailedCase().size());
56+
assertEquals(0, report.getFailedCase().size());
5657
new HdfsCompatTool(conf).printReport(report, System.out);
5758
} finally {
5859
cluster.shutdown();

hadoop-tools/hadoop-compat-bench/src/test/java/org/apache/hadoop/fs/compat/common/TestHdfsCompatFsCommand.java

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -17,6 +17,7 @@
1717
*/
1818
package org.apache.hadoop.fs.compat.common;
1919

20+
import static org.junit.jupiter.api.Assertions.assertEquals;
2021

2122
import org.apache.hadoop.fs.compat.HdfsCompatTool;
2223
import org.apache.hadoop.fs.compat.hdfs.HdfsCompatMiniCluster;
@@ -25,7 +26,6 @@
2526
import org.apache.hadoop.fs.compat.cases.HdfsCompatMkdirTestCases;
2627
import org.apache.hadoop.fs.FileSystem;
2728
import org.apache.hadoop.fs.Path;
28-
import org.junit.jupiter.api.Assertions;
2929
import org.junit.jupiter.api.Test;
3030

3131
import java.io.IOException;
@@ -47,8 +47,8 @@ public void testDfsCompatibility() throws Exception {
4747
HdfsCompatCommand cmd = new TestCommand(uri, suite, conf);
4848
cmd.initialize();
4949
HdfsCompatReport report = cmd.apply();
50-
Assertions.assertEquals(7, report.getPassedCase().size());
51-
Assertions.assertEquals(0, report.getFailedCase().size());
50+
assertEquals(7, report.getPassedCase().size());
51+
assertEquals(0, report.getFailedCase().size());
5252
show(conf, report);
5353
} finally {
5454
if (cluster != null) {
@@ -65,8 +65,8 @@ public void testLocalFsCompatibility() throws Exception {
6565
HdfsCompatCommand cmd = new TestCommand(uri, suite, conf);
6666
cmd.initialize();
6767
HdfsCompatReport report = cmd.apply();
68-
Assertions.assertEquals(1, report.getPassedCase().size());
69-
Assertions.assertEquals(6, report.getFailedCase().size());
68+
assertEquals(1, report.getPassedCase().size());
69+
assertEquals(6, report.getFailedCase().size());
7070
show(conf, report);
7171
cleanup(cmd, conf);
7272
}
@@ -79,8 +79,8 @@ public void testFsCompatibilityWithSuite() throws Exception {
7979
HdfsCompatCommand cmd = new TestCommand(uri, suite, conf);
8080
cmd.initialize();
8181
HdfsCompatReport report = cmd.apply();
82-
Assertions.assertEquals(0, report.getPassedCase().size());
83-
Assertions.assertEquals(6, report.getFailedCase().size());
82+
assertEquals(0, report.getPassedCase().size());
83+
assertEquals(6, report.getFailedCase().size());
8484
show(conf, report);
8585
cleanup(cmd, conf);
8686
}

hadoop-tools/hadoop-compat-bench/src/test/java/org/apache/hadoop/fs/compat/common/TestHdfsCompatInterfaceCoverage.java

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -17,10 +17,10 @@
1717
*/
1818
package org.apache.hadoop.fs.compat.common;
1919

20+
import static org.junit.jupiter.api.Assertions.assertTrue;
2021

2122
import org.apache.hadoop.fs.compat.cases.HdfsCompatBasics;
2223
import org.apache.hadoop.fs.FileSystem;
23-
import org.junit.jupiter.api.Assertions;
2424
import org.junit.jupiter.api.Test;
2525
import org.junit.jupiter.api.Disabled;
2626

@@ -35,7 +35,7 @@ public void testFsCompatibility() {
3535
Set<String> publicMethods = getPublicInterfaces(FileSystem.class);
3636
Set<String> targets = getTargets(HdfsCompatBasics.class);
3737
for (String publicMethod : publicMethods) {
38-
Assertions.assertTrue(
38+
assertTrue(
3939
targets.contains(publicMethod), "Method not tested: " + publicMethod);
4040
}
4141
}

hadoop-tools/hadoop-compat-bench/src/test/java/org/apache/hadoop/fs/compat/common/TestHdfsCompatShellCommand.java

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -17,6 +17,7 @@
1717
*/
1818
package org.apache.hadoop.fs.compat.common;
1919

20+
import static org.junit.jupiter.api.Assertions.assertEquals;
2021

2122
import org.apache.commons.io.FileUtils;
2223
import org.apache.hadoop.fs.compat.HdfsCompatTool;
@@ -25,7 +26,6 @@
2526
import org.apache.hadoop.fs.compat.hdfs.HdfsCompatTestShellScope;
2627
import org.apache.hadoop.conf.Configuration;
2728
import org.junit.jupiter.api.AfterEach;
28-
import org.junit.jupiter.api.Assertions;
2929
import org.junit.jupiter.api.BeforeEach;
3030
import org.junit.jupiter.api.Test;
3131

@@ -55,8 +55,8 @@ public void testDfsCompatibility() throws Exception {
5555
HdfsCompatCommand cmd = new TestCommand(uri, conf);
5656
cmd.initialize();
5757
HdfsCompatReport report = cmd.apply();
58-
Assertions.assertEquals(3, report.getPassedCase().size());
59-
Assertions.assertEquals(0, report.getFailedCase().size());
58+
assertEquals(3, report.getPassedCase().size());
59+
assertEquals(0, report.getFailedCase().size());
6060
show(conf, report);
6161
}
6262

@@ -67,8 +67,8 @@ public void testSkipCompatibility() throws Exception {
6767
HdfsCompatCommand cmd = new TestSkipCommand(uri, conf);
6868
cmd.initialize();
6969
HdfsCompatReport report = cmd.apply();
70-
Assertions.assertEquals(2, report.getPassedCase().size());
71-
Assertions.assertEquals(0, report.getFailedCase().size());
70+
assertEquals(2, report.getPassedCase().size());
71+
assertEquals(0, report.getFailedCase().size());
7272
show(conf, report);
7373
}
7474

0 commit comments

Comments
 (0)