sentry-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From shreepa...@apache.org
Subject git commit: SENTRY-53: Fix test failures caused by SENTRY-41 (Sravya Tirukkovalur via Shreepadma Venugopalan)
Date Thu, 07 Nov 2013 02:40:05 GMT
Updated Branches:
  refs/heads/master 14f10a14c -> a41617c81


SENTRY-53: Fix test failures caused by SENTRY-41 (Sravya Tirukkovalur via Shreepadma Venugopalan)


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

Branch: refs/heads/master
Commit: a41617c814ced681d4feafa78ab748f520999bf8
Parents: 14f10a1
Author: Shreepadma Venugopalan <shreepadma@apache.org>
Authored: Wed Nov 6 18:39:40 2013 -0800
Committer: Shreepadma Venugopalan <shreepadma@apache.org>
Committed: Wed Nov 6 18:39:40 2013 -0800

----------------------------------------------------------------------
 .../apache/sentry/tests/e2e/hive/TestUriPermissions.java | 11 +----------
 1 file changed, 1 insertion(+), 10 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/incubator-sentry/blob/a41617c8/sentry-tests/sentry-tests-hive/src/test/java/org/apache/sentry/tests/e2e/hive/TestUriPermissions.java
----------------------------------------------------------------------
diff --git a/sentry-tests/sentry-tests-hive/src/test/java/org/apache/sentry/tests/e2e/hive/TestUriPermissions.java
b/sentry-tests/sentry-tests-hive/src/test/java/org/apache/sentry/tests/e2e/hive/TestUriPermissions.java
index 6684114..ba651a9 100644
--- a/sentry-tests/sentry-tests-hive/src/test/java/org/apache/sentry/tests/e2e/hive/TestUriPermissions.java
+++ b/sentry-tests/sentry-tests-hive/src/test/java/org/apache/sentry/tests/e2e/hive/TestUriPermissions.java
@@ -16,13 +16,10 @@
  */
 package org.apache.sentry.tests.e2e.hive;
 
-import java.io.File;
-import java.io.FileOutputStream;
 import java.sql.Connection;
 import java.sql.ResultSet;
 import java.sql.Statement;
 
-import com.google.common.io.Resources;
 import junit.framework.Assert;
 
 import org.apache.sentry.provider.file.PolicyFile;
@@ -36,18 +33,12 @@ public class TestUriPermissions extends AbstractTestWithStaticConfiguration
{
   private PolicyFile policyFile;
 
   private static final String dataFile = "/kv1.dat";
-  private String dataFilePath;
+  private String dataFilePath = this.getClass().getResource(dataFile).getFile();
 
   @Before
   public void setup() throws Exception {
     context = createContext();
     policyFile = PolicyFile.setAdminOnServer1(ADMINGROUP);
-    File dataFile = new File(dataDir, SINGLE_TYPE_DATA_FILE_NAME);
-    FileOutputStream to = new FileOutputStream(dataFile);
-    Resources.copy(Resources.getResource(SINGLE_TYPE_DATA_FILE_NAME), to);
-    to.close();
-    dataFilePath = dataFile.getAbsolutePath();
-
   }
 
   @After


Mime
View raw message