aasha commented on a change in pull request #1563:
URL: https://github.com/apache/hive/pull/1563#discussion_r502163365



##########
File path: 
ql/src/test/org/apache/hadoop/hive/ql/exec/repl/TestAtlasDumpTask.java
##########
@@ -96,4 +105,13 @@ public void testAtlasDumpMetrics() throws Exception {
     Assert.assertTrue(eventDetailsCaptor
         
.getAllValues().get(1).toString().contains("{\"dbName\":\"srcDB\",\"dumpEndTime\""));
   }
+
+  @Test
+  public void testAtlasRestClientBuilder() throws SemanticException, 
IOException {
+    mockStatic(UserGroupInformation.class);
+    
when(UserGroupInformation.getLoginUser()).thenReturn(mock(UserGroupInformation.class));
+    AtlasRestClientBuilder atlasRestCleintBuilder = new 
AtlasRestClientBuilder("http://localhost:31000";);
+    AtlasRestClient atlasClient = atlasRestCleintBuilder.getClient(conf);
+    Assert.assertTrue(atlasClient != null);

Review comment:
       hive in test repl is set to true. It will return a No Op Client which 
will never be null.




----------------------------------------------------------------
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.

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