@Test public void testRemoteFileDelete() throws Exception { final String srcPath = "/testDel"; final String file1 = "file1"; Path srcDir = new Path(srcPath); dfs.mkdirs(srcDir); final FSDataOutputStream out1 = dfs.create(new Path(srcPath + "/" + file1)); out1.writeChars("testDelete1"); out1.close(); Assert.assertTrue(dfsClient.exists(srcPath + "/" + file1)); DeleteFileAction deleteFileAction = new DeleteFileAction(); deleteFileAction.setDfsClient(dfsClient); deleteFileAction.setContext(smartContext); Map<String, String> args = new HashMap<>(); args.put(DeleteFileAction.FILE_PATH, dfs.getUri() + srcPath + "/" + file1); deleteFileAction.init(args); deleteFileAction.run(); Assert.assertTrue(deleteFileAction.getExpectedAfterRun()); Assert.assertFalse(dfsClient.exists(srcPath + "/" + file1)); }
@Override public void init(Map<String, String> args) { super.init(args); this.filePath = args.get(FILE_PATH); }
DeleteFileAction extends HdfsAction { @Override public void init(Map<String, String> args) { super.init(args); this.filePath = args.get(FILE_PATH); } }
DeleteFileAction extends HdfsAction { @Override public void init(Map<String, String> args) { super.init(args); this.filePath = args.get(FILE_PATH); }  }
DeleteFileAction extends HdfsAction { @Override public void init(Map<String, String> args) { super.init(args); this.filePath = args.get(FILE_PATH); }  @Override void init(Map<String, String> args); }
DeleteFileAction extends HdfsAction { @Override public void init(Map<String, String> args) { super.init(args); this.filePath = args.get(FILE_PATH); }  @Override void init(Map<String, String> args);  }