use of org.apache.hive.beeline.hs2connection.UserHS2ConnectionFileParser in project hive by apache.
the class TestUserHS2ConnectionFileParser method testNoLocationFoundCase.
/*
* Tests if null value returned when file is not present in any of the lookup locations
*/
@Test
public void testNoLocationFoundCase() throws Exception {
testLocations.add(LOCATION_1);
testLocations.add(LOCATION_2);
testLocations.add(LOCATION_3);
UserHS2ConnectionFileParser testHS2ConfigManager = new UserHS2ConnectionFileParser(testLocations);
Assert.assertTrue(testHS2ConfigManager.getConnectionProperties().isEmpty());
}
use of org.apache.hive.beeline.hs2connection.UserHS2ConnectionFileParser in project hive by apache.
the class TestUserHS2ConnectionFileParser method getParsedUrlFromConfigFile.
private String getParsedUrlFromConfigFile(String filename) throws BeelineHS2ConnectionFileParseException {
String path = HiveTestUtils.getFileFromClasspath(filename);
testLocations.add(path);
UserHS2ConnectionFileParser testHS2ConfigManager = new UserHS2ConnectionFileParser(testLocations);
return HS2ConnectionFileUtils.getUrl(testHS2ConfigManager.getConnectionProperties());
}
Aggregations