public void PartialUnify_PartiallyUnifiableNames_True(string n1, string n2, string[] result) { var name1 = Name.BuildName(n1); var name2 = Name.BuildName(n2); var expectedBindings = result.Select(s => new Substitution(s)); IEnumerable <Substitution> bindings = new List <Substitution>(); var isPartiallyUnifiable = Unifier.PartialUnify(name1, name2, out bindings); Assert.That(isPartiallyUnifiable); if (result.Any()) { Assert.That(bindings, Is.EquivalentTo(expectedBindings)); } else { Assert.That(bindings == null); } }