public Boolean fileExists( File dir, String path ) {
    try {
      FileProvider<File> fileProvider = providerService.get( dir.getProvider() );
      return fileProvider.fileExists( dir, path, space );
    } catch ( InvalidFileProviderException | FileException e ) {
      return false;
    }
  }
@Test
  public void testFileExists() {
    TestDirectory testDirectory = new TestDirectory();
    testDirectory.setPath( "/directory1" );
    Assert.assertTrue( fileController.fileExists( testDirectory, "/directory1/file1" ) );
    Assert.assertFalse( fileController.fileExists( testDirectory, "/directory1/file5" ) );
  }