@Test
public void rankClustersToAllocationTest() {

    List<ClusterResourcesAvailableToStart> clustersAvailableToStart = createClustersWithScore();
    Mockito.doReturn(clustersAvailableToStart).when(spyAlgorithm).cloneListOfClusters(clustersAvailableToStart);
    Mockito.doNothing().when(spyAlgorithm).setClustersScore(clustersAvailableToStart);
    Mockito.doNothing().when(spyAlgorithm).sortClustersDownwardScore(clustersAvailableToStart);
    spyAlgorithm.rankClustersToAllocation(clustersAvailableToStart);
    InOrder inOrder = Mockito.inOrder(spyAlgorithm);
    inOrder.verify(spyAlgorithm).cloneListOfClusters(clustersAvailableToStart);
    inOrder.verify(spyAlgorithm).setClustersScore(clustersAvailableToStart);
    inOrder.verify(spyAlgorithm).sortClustersDownwardScore(clustersAvailableToStart);
}