chibenwa commented on a change in pull request #781:
URL: https://github.com/apache/james-project/pull/781#discussion_r766286597



##########
File path: 
server/protocols/jmap-rfc-8621-integration-tests/jmap-rfc-8621-integration-tests-common/src/main/scala/org/apache/james/jmap/rfc8621/contract/custom/authentication/strategy/ModularizeJmapRFC8621AuthenticationStrategyContract.java
##########
@@ -60,8 +61,6 @@
 
     private GuiceJamesServer jmapServer;
 
-    protected abstract GuiceJamesServer createJmapServer(GuiceJamesServer 
basedServer, Optional<List<String>> authOverride);
-
     public void 
setupJamesServerWithCustomAuthenticationStrategy(GuiceJamesServer basedServer, 
Optional<List<String>> authOverride) throws Throwable {
         jmapServer = createJmapServer(basedServer, authOverride);

Review comment:
       ```suggestion
           jmapServer = baseServer
               .overrideWith(binder -> 
binder.bind(JmapRfc8621Configuration.class)
                   
.toInstance(JmapRfc8621Configuration.LOCALHOST_CONFIGURATION()
                       
.withAuthenticationStrategies(authOverride.orElse(null))));
   ```

##########
File path: 
server/protocols/jmap-rfc-8621-integration-tests/jmap-rfc-8621-integration-tests-common/src/main/scala/org/apache/james/jmap/rfc8621/contract/custom/authentication/strategy/ModularizeJmapRFC8621AuthenticationStrategyContract.java
##########
@@ -60,8 +61,6 @@
 
     private GuiceJamesServer jmapServer;
 
-    protected abstract GuiceJamesServer createJmapServer(GuiceJamesServer 
basedServer, Optional<List<String>> authOverride);
-
     public void 
setupJamesServerWithCustomAuthenticationStrategy(GuiceJamesServer basedServer, 
Optional<List<String>> authOverride) throws Throwable {
         jmapServer = createJmapServer(basedServer, authOverride);

Review comment:
       BTW this `.orElse(null)` is uggly. Can we get rid of that?




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