/// <summary> /// Returns true if one item selected in the first output selection is not selected in the second or vice versa /// </summary> public static bool DiffersFrom(this OutputSelections first, OutputSelections second) { if (second == null) { return(true); } if (first.Count() != second.Count()) { return(true); } foreach (var firstOutput in first.AllOutputs) { var secondOutput = second.AllOutputs.FirstOrDefault(x => string.Equals(x.Path, firstOutput.Path)); if (secondOutput == null) { return(true); } } return(false); }
public void should_make_sure_that_all_quantities_defined_in_the_results_are_also_selected_as_output_for_the_simulation() { _simulationSettings.Count().ShouldBeEqualTo(2); _simulationSettings.Select(x => x.Path).ShouldContain("PATH1", "PATH2"); }