-
Couldn't load subscription status.
- Fork 9.1k
HDFS-12431. [JDK17] Upgrade JUnit from 4 to 5 in hadoop-hdfs Part10. #7841
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
|
🎊 +1 overall
This message was automatically generated. |
|
LGTM. |
|
🎊 +1 overall
This message was automatically generated. |
|
|
||
| // Verify that the storages match before and after the test | ||
| Assert.assertArrayEquals(storageInfos, dnDescriptor.getStorageInfos()); | ||
| Assertions.assertArrayEquals(storageInfos, dnDescriptor.getStorageInfos()); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Assertions. It would be best if they could be extracted to imports.
| } catch (Exception e) { | ||
| e.printStackTrace(); | ||
| Assert.fail("Failed to start BlockChecker: " + e); | ||
| Assertions.fail("Failed to start BlockChecker: " + e); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Assertions. It would be best if they could be extracted to imports.
| InetSocketAddress nnAddr) throws IOException { | ||
| Assert.assertEquals(nnSocketAddr, nnAddr); | ||
| return namenode; | ||
| Assertions.assertEquals(nnSocketAddr, nnAddr); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Assertions. It would be best if they could be extracted to imports.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks a lot for your review—I'll update the code right away!
| dnNewDataDirs.append(newVol.getAbsolutePath()); | ||
| } | ||
| try { | ||
| assertThat( |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
nit: You may consider using assertEquals
assertEquals(
dn.getConf().get(DFSConfigKeys.DFS_DATANODE_DATA_DIR_KEY),
dn.reconfigurePropertyImpl(
DFSConfigKeys.DFS_DATANODE_DATA_DIR_KEY,
dnNewDataDirs.toString()));
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks for the suggestion—I'll update the code right away!
dc2c458 to
f047a51
Compare
|
💔 -1 overall
This message was automatically generated. |
|
🎊 +1 overall
This message was automatically generated. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
+1. I'll merge this shortly.
|
I committed this to trunk. Thank you @zhtttylz . Thank you @slfan1989 for reviewing. |
|
Thanks @cnauroth and @slfan1989 for reviewing and merging! |
Description of PR
JIRA:HDFS-12431. Upgrade JUnit from 4 to 5 in hadoop-hdfs Part10.
How was this patch tested?
Junit Test.
For code changes:
LICENSE,LICENSE-binary,NOTICE-binaryfiles?