hive-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From hashut...@apache.org
Subject svn commit: r1603018 - /hive/trunk/common/src/test/org/apache/hadoop/hive/conf/TestHiveConf.java
Date Mon, 16 Jun 2014 22:57:31 GMT
Author: hashutosh
Date: Mon Jun 16 22:57:30 2014
New Revision: 1603018

URL: http://svn.apache.org/r1603018
Log:
HIVE-7201 : Fix TestHiveConf#testConfProperties test case (Pankit Thapar via Ashutosh Chauhan)

Modified:
    hive/trunk/common/src/test/org/apache/hadoop/hive/conf/TestHiveConf.java

Modified: hive/trunk/common/src/test/org/apache/hadoop/hive/conf/TestHiveConf.java
URL: http://svn.apache.org/viewvc/hive/trunk/common/src/test/org/apache/hadoop/hive/conf/TestHiveConf.java?rev=1603018&r1=1603017&r2=1603018&view=diff
==============================================================================
--- hive/trunk/common/src/test/org/apache/hadoop/hive/conf/TestHiveConf.java (original)
+++ hive/trunk/common/src/test/org/apache/hadoop/hive/conf/TestHiveConf.java Mon Jun 16 22:57:30
2014
@@ -17,7 +17,7 @@
  */
 package org.apache.hadoop.hive.conf;
 
-import org.apache.hadoop.conf.Configuration;
+import org.apache.hadoop.mapred.JobConf;
 import org.apache.hadoop.fs.Path;
 import org.apache.hadoop.hive.conf.HiveConf.ConfVars;
 import org.apache.hadoop.util.Shell;
@@ -36,7 +36,7 @@ public class TestHiveConf {
   @Test
   public void testHiveSitePath() throws Exception {
     String expectedPath = HiveTestUtils.getFileFromClasspath("hive-site.xml");
-    String hiveSiteLocation = new HiveConf().getHiveSiteLocation().getPath();
+    String hiveSiteLocation = HiveConf.getHiveSiteLocation().getPath();
     if (Shell.WINDOWS) {
       // Do case-insensitive comparison on Windows, as drive letter can have different case.
       expectedPath = expectedPath.toLowerCase();
@@ -46,7 +46,7 @@ public class TestHiveConf {
   }
 
   private void checkHadoopConf(String name, String expectedHadoopVal) throws Exception {
-    Assert.assertEquals(expectedHadoopVal, new Configuration().get(name));
+    Assert.assertEquals(expectedHadoopVal, new JobConf(HiveConf.class).get(name));
   }
 
   private void checkConfVar(ConfVars var, String expectedConfVarVal) throws Exception {



Mime
View raw message