public void width_is_the_text_width() { var text = "a bunch of text"; var line = new PlainLine(text); line.Width.ShouldEqual(text.Length); }
public void write() { var text = "a bunch of text"; var line = new PlainLine(text); var writer = MockRepository.GenerateMock<TextWriter>(); line.Write(writer); writer.AssertWasCalled(x => x.WriteLine(text)); }
public void AddText(string text) { var line = new PlainLine(text); _lines.Add(line); }