@Test
public void testRun() throws Exception {
String testJarPath = getTestJarPath("BatchWordCount.jar").getAbsolutePath();
Configuration configuration = new Configuration();
configuration.setString(JobManagerOptions.ADDRESS, "localhost");
configuration.setInteger(JobManagerOptions.PORT, 8081);
FlinkYarnSessionCli yarnCLI = new TestingFlinkYarnSessionCli(
configuration,
tmp.getRoot().getAbsolutePath(),
"y",
"yarn");
{
String[] parameters = {"-m", "yarn-cluster", "-yn", "1", "-p", "2", "-d", testJarPath};
verifyCliFrontend(yarnCLI, parameters, 2, true, true);
}
{
String[] parameters = {"-m", "yarn-cluster", "-yn", "1", "-p", "2", "-yd", testJarPath};
verifyCliFrontend(yarnCLI, parameters, 2, true, true);
}
}