public void Test4x(string html) { var sut = new TextNodeFilter(WhitespaceOption.Normalize); var source = ToComparisonSource(html); sut.Filter(source, FilterDecision.Keep).ShouldBe(FilterDecision.Keep); sut.Filter(source, FilterDecision.Exclude).ShouldBe(FilterDecision.Exclude); }
public void Test1(string whitespace) { var sut = new TextNodeFilter(WhitespaceOption.Preserve); var source = ToComparisonSource(whitespace); sut.Filter(source, FilterDecision.Keep).ShouldBe(FilterDecision.Keep); sut.Filter(source, FilterDecision.Exclude).ShouldBe(FilterDecision.Exclude); }
public void Tes76(string html) { var sut = new TextNodeFilter(WhitespaceOption.Normalize); var root = ToNode(html); var source = new ComparisonSource(root.FirstChild.FirstChild.FirstChild, 0, "dummypath", ComparisonSourceType.Control); sut.Filter(source, FilterDecision.Keep).ShouldBe(FilterDecision.Keep); }
public void Test51(string tag, WhitespaceOption whitespaceOption) { var sut = new TextNodeFilter(WhitespaceOption.Normalize); var pre = ToNode($"<{tag} diff:whitespace=\"{whitespaceOption.ToString()}\">\n\t</{tag}>"); var source = pre.FirstChild.ToComparisonSource(0, ComparisonSourceType.Control); sut.Filter(source, FilterDecision.Keep).ShouldBe(FilterDecision.Exclude); }
public void Test5(string tag) { var sut = new TextNodeFilter(WhitespaceOption.Normalize); var pre = ToNode($"<{tag}> \n\t </{tag}>"); var source = pre.FirstChild.ToComparisonSource(0, ComparisonSourceType.Control); sut.Filter(source, FilterDecision.Keep).ShouldBe(FilterDecision.Keep); }