You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@cloudstack.apache.org by GitBox <gi...@apache.org> on 2021/02/12 15:27:47 UTC

[GitHub] [cloudstack] GutoVeronezi commented on a change in pull request #4668: Adjust tests to fix a problem with the container builders (https://github.com/khos2ow/cloudstack-deb-builder)

GutoVeronezi commented on a change in pull request #4668:
URL: https://github.com/apache/cloudstack/pull/4668#discussion_r575304316



##########
File path: plugins/ca/root-ca/src/test/java/org/apache/cloudstack/ca/provider/RootCAProviderTest.java
##########
@@ -133,17 +128,17 @@ public void testRevokeCertificate() throws Exception {
 
     @Test
     public void testCreateSSLEngineWithoutAuthStrictness() throws Exception {
-        overrideDefaultConfigValue(RootCAProvider.rootCAAuthStrictness, "_defaultValue", "false");
+        provider.rootCAAuthStrictness = Mockito.mock(ConfigKey.class);
+        Mockito.when(provider.rootCAAuthStrictness.value()).thenReturn(Boolean.FALSE);
         final SSLEngine e = provider.createSSLEngine(SSLUtils.getSSLContext(), "/1.2.3.4:5678", null);
-        Assert.assertFalse(e.getUseClientMode());

Review comment:
       @rhtyd actually if you take a look at this file in [4.15](https://github.com/apache/cloudstack/blob/4.15/plugins/ca/root-ca/src/test/java/org/apache/cloudstack/ca/provider/RootCAProviderTest.java), you will notice that this line is already removed, I made the changes using it as a reference.   
   My PR does not change the test case, it just change the way that variable is mocked.




----------------------------------------------------------------
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:
users@infra.apache.org