Ejemplo n.º 1
0
 public void Build_GivenWhitespaceTitle_ThrowsArgumentOutOfRangeException()
 {
     Assert.Throws <ArgumentOutOfRangeException>(
         () => InterpretationSection.Build(" ", new List <string> {
         "Paragraph 1"
     }));
 }
Ejemplo n.º 2
0
 public void Build_GivenEmptyParagraphsList_ThrowsArgumentOutOfRangeException()
 {
     Assert.Throws <ArgumentException>(
         () => InterpretationSection.Build("Title", new List <string>()));
 }
Ejemplo n.º 3
0
 public void Build_GivenNullParagraphsList_ThrowsArgumentNullException()
 {
     Assert.Throws <ArgumentNullException>(
         () => InterpretationSection.Build("Title", null));
 }
Ejemplo n.º 4
0
 private static string GetParagraphsText(InterpretationSection section)
 {
     return(section.Paragraphs.Aggregate(string.Empty, (current, parapraph)
                                         => current + parapraph + Environment.NewLine + Environment.NewLine));
 }