sqoop-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From a..@apache.org
Subject sqoop git commit: SQOOP-1697: Sqoop2: HDFS Connector TestLoader.verifyOutput have invalid default value for Hadoop 1
Date Sun, 09 Nov 2014 07:24:58 GMT
Repository: sqoop
Updated Branches:
  refs/heads/branch-1.99.4 448cf576a -> a193e1cf8


SQOOP-1697: Sqoop2: HDFS Connector TestLoader.verifyOutput have invalid default value for
Hadoop 1

(Jarek Jarcec Cecho via Abraham Elmahrek)


Project: http://git-wip-us.apache.org/repos/asf/sqoop/repo
Commit: http://git-wip-us.apache.org/repos/asf/sqoop/commit/a193e1cf
Tree: http://git-wip-us.apache.org/repos/asf/sqoop/tree/a193e1cf
Diff: http://git-wip-us.apache.org/repos/asf/sqoop/diff/a193e1cf

Branch: refs/heads/branch-1.99.4
Commit: a193e1cf8453a1b271fb00fc8f79f5aabce6a5ed
Parents: 448cf57
Author: Abraham Elmahrek <abraham@elmahrek.com>
Authored: Sat Nov 8 23:16:52 2014 -0800
Committer: Abraham Elmahrek <abraham@elmahrek.com>
Committed: Sat Nov 8 23:18:55 2014 -0800

----------------------------------------------------------------------
 .../test/java/org/apache/sqoop/connector/hdfs/TestLoader.java  | 6 +++++-
 1 file changed, 5 insertions(+), 1 deletion(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/sqoop/blob/a193e1cf/connector/connector-hdfs/src/test/java/org/apache/sqoop/connector/hdfs/TestLoader.java
----------------------------------------------------------------------
diff --git a/connector/connector-hdfs/src/test/java/org/apache/sqoop/connector/hdfs/TestLoader.java
b/connector/connector-hdfs/src/test/java/org/apache/sqoop/connector/hdfs/TestLoader.java
index a30d410..b404c34 100644
--- a/connector/connector-hdfs/src/test/java/org/apache/sqoop/connector/hdfs/TestLoader.java
+++ b/connector/connector-hdfs/src/test/java/org/apache/sqoop/connector/hdfs/TestLoader.java
@@ -159,7 +159,11 @@ public class TestLoader extends TestHdfsBase {
             break;
 
           case DEFAULT:
-            Assert.assertTrue(codec.getClass().getCanonicalName().indexOf("Deflate") != -1);
+            if(org.apache.hadoop.util.VersionInfo.getVersion().matches("\\b1\\.\\d\\.\\d"))
{
+              Assert.assertTrue(codec.getClass().getCanonicalName().indexOf("Default") !=
-1);
+            } else {
+              Assert.assertTrue(codec.getClass().getCanonicalName().indexOf("Deflate") !=
-1);
+            }
             break;
 
           case NONE:


Mime
View raw message