steveloughran commented on a change in pull request #3263:
URL: https://github.com/apache/hadoop/pull/3263#discussion_r682642543



##########
File path: 
hadoop-tools/hadoop-aws/src/test/java/org/apache/hadoop/fs/contract/s3a/ITestS3AContractSeek.java
##########
@@ -143,7 +143,8 @@ protected AbstractFSContract createContract(Configuration 
conf) {
   public void teardown() throws Exception {
     super.teardown();
     S3AFileSystem fs = getFileSystem();
-    if (fs.getConf().getBoolean(FS_S3A_IMPL_DISABLE_CACHE, false)) {
+    if (fs != null && fs.getConf().getBoolean(FS_S3A_IMPL_DISABLE_CACHE,

Review comment:
       they are. IF test setup() fails then fs may be null, teardown will be 
called and you'll see the error in teardown (here an NPE) rather than whatever 
caused setup failure. 




-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]



---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to