public static FileSystem createFileSystem() throws IOException {
    FileSystem fs = Jimfs.newFileSystem(Configuration.unix());

    // Just some random operations to verify that basic things work on the created file system.
    writeAndRead(fs, "foo.txt", "blah");

    return fs;
  }
This method is really just testing that {@code Jimfs.newFileSystem()} succeeds. Without special
handling, when the system class loader loads our {@code FileSystemProvider} implementation as a
service and this code (the user code) is loaded in a separate class loader, the system-loaded
provider won't see the instance of {@code Configuration} we give it as being an instance of the
{@code Configuration} it's expecting (they're completely separate classes) and creation of the
file system will fail.
jimfs/src/test/java/com/google/common/jimfs/ClassLoaderTest.java