extraArgs.add(passwordFilePath);
String[] argv = getCommonArgs(false, extraArgs);
Configuration conf = getConf();
SqoopOptions in = getSqoopOptions(conf);
ImportTool importTool = new ImportTool();
SqoopOptions out = importTool.parseArguments(argv, conf, in, true);
assertNotNull(out.getPassword());
importTool.validateOptions(out);
fail("Either password or passwordPath must be specified but not both.");
} catch (Exception e) {
assertTrue(e.getMessage().contains("Either password or path to a "
+ "password file must be specified but not both"));
}