### Question:
TailSource extends EventSource.Base { @Override public void close() throws IOException { synchronized (this) { done = true; thd = null; } } TailSource(File f, long offset, long waitTime);  TailSource(File f, long offset, long waitTime, boolean startFromEnd);  TailSource(long waitTime); synchronized void removeCursor(Cursor cursor); @Override void close(); @Override Event next(); @Override synchronized void open(); static SourceBuilder builder(); static SourceBuilder multiTailBuilder(); static final String A_TAILSRCFILE; }### Answer:
@Test public void testFileOutputStream() throws IOException { File tmp = File.createTempFile("tmp-", ".tmp"); FileOutputStream f = new FileOutputStream(tmp); f.write("0123456789".getBytes()); f.close(); assertEquals(10, tmp.length()); f = new FileOutputStream(tmp); f.write("01234".getBytes()); f.close(); assertEquals(5, tmp.length()); }