Repository: incubator-sentry Updated Branches: refs/heads/master b5bbcf94e -> 4a4bfecfe
SENTRY-930: Improve TestDbDDLAuditLog for keep consistent with Hive metadata.(Dapeng Sun, reviewed by Colin Ma) Project: http://git-wip-us.apache.org/repos/asf/incubator-sentry/repo Commit: http://git-wip-us.apache.org/repos/asf/incubator-sentry/commit/695d60d0 Tree: http://git-wip-us.apache.org/repos/asf/incubator-sentry/tree/695d60d0 Diff: http://git-wip-us.apache.org/repos/asf/incubator-sentry/diff/695d60d0 Branch: refs/heads/master Commit: 695d60d075c4c735a555f350f2d953761c219cdf Parents: b5bbcf9 Author: Sun Dapeng <[email protected]> Authored: Tue Oct 27 09:13:12 2015 +0800 Committer: Sun Dapeng <[email protected]> Committed: Tue Oct 27 09:13:12 2015 +0800 ---------------------------------------------------------------------- .../org/apache/sentry/tests/e2e/dbprovider/TestDbDDLAuditLog.java | 3 +++ 1 file changed, 3 insertions(+) ---------------------------------------------------------------------- http://git-wip-us.apache.org/repos/asf/incubator-sentry/blob/695d60d0/sentry-tests/sentry-tests-hive/src/test/java/org/apache/sentry/tests/e2e/dbprovider/TestDbDDLAuditLog.java ---------------------------------------------------------------------- diff --git a/sentry-tests/sentry-tests-hive/src/test/java/org/apache/sentry/tests/e2e/dbprovider/TestDbDDLAuditLog.java b/sentry-tests/sentry-tests-hive/src/test/java/org/apache/sentry/tests/e2e/dbprovider/TestDbDDLAuditLog.java index 8613034..3afd6b2 100644 --- a/sentry-tests/sentry-tests-hive/src/test/java/org/apache/sentry/tests/e2e/dbprovider/TestDbDDLAuditLog.java +++ b/sentry-tests/sentry-tests-hive/src/test/java/org/apache/sentry/tests/e2e/dbprovider/TestDbDDLAuditLog.java @@ -84,6 +84,9 @@ public class TestDbDDLAuditLog extends AbstractTestWithStaticConfiguration { fieldValueMap.put(Constants.LOG_FIELD_IP_ADDRESS, null); assertAuditLog(fieldValueMap); + statement.execute("create database " + dbName); + statement.execute("use " + dbName); + statement.execute("CREATE TABLE " + tableName + " (c1 string)"); statement.execute("GRANT ALL ON DATABASE " + dbName + " TO ROLE " + roleName); fieldValueMap.clear(); fieldValueMap.put(Constants.LOG_FIELD_OPERATION, Constants.OPERATION_GRANT_PRIVILEGE);
