public void TestIsOneHeaderOneTag() { var outline = new Outline(); outline.SetHeader("# One "); var result = outline.GetTags(); Assert.Single(result.ToArray()); }
public void TestIsOneHeaderTwoTagReplace() { var outline = new Outline(); outline.SetHeader("# One Two"); outline.SetHeader("# OneA TwoA"); var result = outline.GetTags(); Assert.Equal(2, result.Length); Assert.Equal("OneA", result[0]); Assert.Equal("TwoA", result[1]); }
public void TestIsLevelThreeOnly() { var outline = new Outline(); outline.SetHeader(" ### One Two"); var result = outline.GetTags(); Assert.Equal(2, result.Length); Assert.Equal("One", result[0]); Assert.Equal("Two", result[1]); }
public void TestIsTwoHeaderTwoReplace() { var outline = new Outline(); outline.SetHeader("# One Two"); outline.SetHeader("## OneB TwoB"); outline.SetHeader("# OneC TwoC"); var result = outline.GetTags(); Assert.Equal(2, result.Length); Assert.Equal("OneC", result[0]); Assert.Equal("TwoC", result[1]); }
public void TestIsTwoHeaderTwo() { var outline = new Outline(); outline.SetHeader("# One Two"); outline.SetHeader("## OneB TwoB"); var result = outline.GetTags(); Assert.Equal(4, result.Length); Assert.Equal("One", result[0]); Assert.Equal("Two", result[1]); Assert.Equal("OneB", result[2]); Assert.Equal("TwoB", result[3]); }