public void testNonEmpty_read_singleByte() throws IOException {
      fillContent("123456");
      assertEquals(1, file.read(0));
      assertEquals(2, file.read(1));
      assertEquals(6, file.read(5));
      assertEquals(-1, file.read(6));
      assertEquals(-1, file.read(100));
    }
Actual test cases for testing RegularFiles.
jimfs/src/test/java/com/google/common/jimfs/RegularFileTest.java