dlmarion commented on code in PR #5256:
URL: https://github.com/apache/accumulo/pull/5256#discussion_r1928890884


##########
server/base/src/test/java/org/apache/accumulo/server/security/handler/ZKAuthenticatorTest.java:
##########
@@ -144,14 +145,16 @@ public void testUserAuthentication() throws Exception {
     var instanceId = InstanceId.of("example");
     ZooSession zk = createMock(ZooSession.class);
     ServerContext context = MockServerContext.getWithMockZK(zk);
+    ZooCache zc = createMock(ZooCache.class);
     expect(context.zkUserPath()).andReturn(ZooUtil.getRoot(instanceId) + 
Constants.ZUSERS)
         .anyTimes();
     expect(zk.getChildren(anyObject(), 
anyObject())).andReturn(Arrays.asList(principal)).anyTimes();
     expect(zk.exists(matches(ZooUtil.getRoot(instanceId) + Constants.ZUSERS + 
"/" + principal),
         anyObject(Watcher.class))).andReturn(new Stat()).anyTimes();
-    expect(zk.getData(matches(ZooUtil.getRoot(instanceId) + Constants.ZUSERS + 
"/" + principal),
-        anyObject(), anyObject())).andReturn(newHash).once();
-    replay(context, zk);
+    expect(context.getZooCache()).andReturn(zc).anyTimes();
+    expect(zc.get(matches(ZooUtil.getRoot(instanceId) + Constants.ZUSERS + "/" 
+ principal)))

Review Comment:
   Removed these in a481f9b



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

Reply via email to