public void testEmpty_write_noBytesBuffer_atNonZeroPosition() throws IOException {
      ByteBuffer buffer = ByteBuffer.allocate(0);
      file.write(5, buffer);
      assertContentEquals(bytes("00000"), file);
    }
Actual test cases for testing RegularFiles.
jimfs/src/test/java/com/google/common/jimfs/RegularFileTest.java