@Override public boolean renameForce(String changetoName) { FileSystem fs; try { fs = fileStatus.getPath().getFileSystem(FileFactory.getConfiguration()); if (fs instanceof ViewFileSystem) { fs.delete(new Path(changetoName), true); fs.rename(fileStatus.getPath(), new Path(changetoName)); return true; } else { return false; } } catch (IOException e) { LOGGER.error("Exception occured" + e.getMessage()); return false; } }
@Test public void testGetMountPoints() { ViewFileSystem viewfs = (ViewFileSystem) fsView; MountPoint[] mountPoints = viewfs.getMountPoints(); Assert.assertEquals(getExpectedMountPoints(), mountPoints.length); }