### Question:
Line { public int getLineNumber() { return lineNumber; } Line(int lineNumber, int offset, String text); boolean isEmpty(); String getText(); int getOffset(); int getLineNumber(); Line segment(int offset, int length); Locator toLocator(); @Override String toString();  }### Answer:
@Test public void getLineNumber() { assertEquals(0, new Line(0, 1, "abc").getLineNumber()); assertEquals(1, new Line(1, 1, "abc").getLineNumber()); }