public static Set<ServiceResponse> getServices(AmbariManagementController controller,
                                                 Set<ServiceRequest> requests)
      throws AmbariException, NoSuchFieldException, IllegalAccessException {
    ServiceResourceProvider provider = getServiceProvider(controller);
    return provider.getServices(requests);
  }
This factory method allows to define custom MaintenanceStateHelper mock.
ambari-server/src/test/java/org/apache/ambari/server/controller/internal/ServiceResourceProviderTest.java