@Test
public void getNonExistingSensitivityValueByFactor() {

    List<SensitivityValue> values = new ArrayList<>();
    values.add(new SensitivityValue(factorOk, Double.NaN, Double.NaN, Double.NaN));
    values.add(new SensitivityValue(factorNok, Double.NaN, Double.NaN, Double.NaN));
    SensitivityAnalysisResult results = new SensitivityAnalysisResult(true, Collections.emptyMap(), "", values, Collections.emptyMap());
    SensitivityFactor wrongFactor = Mockito.mock(SensitivityFactor.class);
    Mockito.when(wrongFactor.getFunction()).thenReturn(Mockito.mock(SensitivityFunction.class));
    Mockito.when(wrongFactor.getVariable()).thenReturn(Mockito.mock(SensitivityVariable.class));
    exception.expect(NoSuchElementException.class);
    results.getSensitivityValue(wrongFactor);
}