demery-pivotal commented on a change in pull request #7357:
URL: https://github.com/apache/geode/pull/7357#discussion_r805084610



##########
File path: 
geode-core/src/test/java/org/apache/geode/internal/cache/tier/sockets/ServerConnectionTest.java
##########
@@ -276,4 +278,26 @@ public void 
doNormalMessageShouldNotProcessMessageWhenTerminated() {
     assertThat(spy.getProcessMessages()).isFalse();
     verify(spy, never()).resumeThreadMonitoring();
   }
+
+  @Test
+  public void cleanClientAuthShouldNullIt() {
+    ClientUserAuths clientUserAuths = mock(ClientUserAuths.class);
+    ServerConnection spy = spy(serverConnection);
+    spy.setClientUserAuths(clientUserAuths);
+    spy.cleanClientAuths();
+    assertThat(spy.getClientUserAuths()).isNull();
+  }
+
+  @Test
+  public void handleTerminationShouldNotNullClientAuths() {
+    when(acceptor.getClientHealthMonitor()).thenReturn(clientHealthMonitor);

Review comment:
       These tests are better, but they still test internal implementation 
details. Instead of asserting the value of this field, is there a way to 
observe the _effects_ of the field being null or not null? That is, what later 
call does the right thing only when this field has the correct value?




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