diff --git a/hbase-shell/src/test/java/org/apache/hadoop/hbase/client/TestShell.java b/hbase-shell/src/test/java/org/apache/hadoop/hbase/client/TestShell.java index dde8fe7..8714d2f 100644 --- a/hbase-shell/src/test/java/org/apache/hadoop/hbase/client/TestShell.java +++ b/hbase-shell/src/test/java/org/apache/hadoop/hbase/client/TestShell.java @@ -30,7 +30,7 @@ import org.junit.experimental.categories.Category; public class TestShell extends AbstractTestShell { @Test public void testRunShellTests() throws IOException { - System.setProperty("shell.test.exclude", "replication_admin_test.rb"); + System.setProperty("shell.test.exclude", "replication_admin_test.rb,security_admin_test.rb"); // Start all ruby tests jruby.runScriptlet(PathType.ABSOLUTE, "src/test/ruby/tests_runner.rb"); } diff --git a/hbase-shell/src/test/ruby/hbase/replication_admin_test.rb b/hbase-shell/src/test/ruby/hbase/replication_admin_test.rb index 648efa7..fcf35c3 100644 --- a/hbase-shell/src/test/ruby/hbase/replication_admin_test.rb +++ b/hbase-shell/src/test/ruby/hbase/replication_admin_test.rb @@ -30,7 +30,7 @@ module Hbase include TestHelpers def setup - @test_name = "hbase_shell_tests_table" + @test_name = "rep_admin_tests_table" @peer_id = '1' setup_hbase diff --git a/hbase-shell/src/test/ruby/hbase/security_admin_test.rb b/hbase-shell/src/test/ruby/hbase/security_admin_test.rb index 6ecfb98..e5566ac 100644 --- a/hbase-shell/src/test/ruby/hbase/security_admin_test.rb +++ b/hbase-shell/src/test/ruby/hbase/security_admin_test.rb @@ -33,7 +33,7 @@ module Hbase def setup setup_hbase # Create test table if it does not exist - @test_name = "hbase_shell_tests_table" + @test_name = "sec_admin_tests_table" create_test_table(@test_name) # Create table test table name @@ -55,6 +55,7 @@ module Hbase end define_test "Grant should set access rights appropriately" do + @test_name = "grant_admin_tests_table" drop_test_table(@test_name) create_test_table(@test_name) table = table(@test_name) diff --git a/hbase-shell/src/test/ruby/hbase/table_test.rb b/hbase-shell/src/test/ruby/hbase/table_test.rb index 184e0d4..e4d8dc4 100644 --- a/hbase-shell/src/test/ruby/hbase/table_test.rb +++ b/hbase-shell/src/test/ruby/hbase/table_test.rb @@ -47,7 +47,7 @@ module Hbase def setup setup_hbase # Create test table if it does not exist - @test_name = "hbase_shell_tests_table" + @test_name = "table_tests_table" create_test_table(@test_name) @test_table = table(@test_name) end diff --git a/hbase-shell/src/test/ruby/hbase/visibility_labels_admin_test.rb b/hbase-shell/src/test/ruby/hbase/visibility_labels_admin_test.rb index 47ac292..f724d99 100644 --- a/hbase-shell/src/test/ruby/hbase/visibility_labels_admin_test.rb +++ b/hbase-shell/src/test/ruby/hbase/visibility_labels_admin_test.rb @@ -32,7 +32,7 @@ module Hbase def setup setup_hbase - @test_name = "hbase_shell_tests_table" + @test_name = "vis_labels_tests_table" @test_table = table(@test_name) # Create table test table name create_test_table(@test_name) diff --git a/hbase-shell/src/test/java/org/apache/hadoop/hbase/client/TestSecurityShell.java b/hbase-shell/src/test/java/org/apache/hadoop/hbase/client/TestSecurityShell.java new file mode 100644 index 0000000..b8e2cab --- /dev/null +++ b/hbase-shell/src/test/java/org/apache/hadoop/hbase/client/TestSecurityShell.java @@ -0,0 +1,37 @@ +/** + * Licensed to the Apache Software Foundation (ASF) under one + * or more contributor license agreements. See the NOTICE file + * distributed with this work for additional information + * regarding copyright ownership. The ASF licenses this file + * to you under the Apache License, Version 2.0 (the + * "License"); you may not use this file except in compliance + * with the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +package org.apache.hadoop.hbase.client; + +import java.io.IOException; + +import org.apache.hadoop.hbase.testclassification.LargeTests; +import org.jruby.embed.PathType; +import org.junit.Test; +import org.junit.experimental.categories.Category; + +@Category({ LargeTests.class }) +public class TestSecurityShell extends AbstractTestShell { + + @Test + public void testRunShellTests() throws IOException { + System.setProperty("shell.test.include", "security_admin_test.rb"); + // Start all ruby tests + jruby.runScriptlet(PathType.ABSOLUTE, "src/test/ruby/tests_runner.rb"); + } + +}