@Test
    public void testTailBeforeRead() throws IOException {
        TailStream stream = new TailStream(generateStream(0, 100), 50);
        assertEquals(0, stream.getTail().length, "Wrong buffer length");
        stream.close();
    }
Tests whether the tail buffer can be obtained before data was read.
tika-core/src/test/java/org/apache/tika/io/TailStreamTest.java