ambari-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From jonathanhur...@apache.org
Subject ambari git commit: AMBARI-9741 - Ranger Python Test Fails Because Of Missing Python Path For Common Services (jonathanhurley)
Date Sun, 22 Feb 2015 21:03:46 GMT
Repository: ambari
Updated Branches:
  refs/heads/trunk 6d44e51e2 -> 6eb571c2b


AMBARI-9741 - Ranger Python Test Fails Because Of Missing Python Path For Common Services
(jonathanhurley)


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

Branch: refs/heads/trunk
Commit: 6eb571c2b8c6071e4c77ff3879b5f10315202d21
Parents: 6d44e51
Author: Jonathan Hurley <jhurley@hortonworks.com>
Authored: Sun Feb 22 15:47:18 2015 -0500
Committer: Jonathan Hurley <jhurley@hortonworks.com>
Committed: Sun Feb 22 15:47:18 2015 -0500

----------------------------------------------------------------------
 .../src/test/python/stacks/2.2/RANGER/test_ranger_usersync.py | 7 +++++++
 1 file changed, 7 insertions(+)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/ambari/blob/6eb571c2/ambari-server/src/test/python/stacks/2.2/RANGER/test_ranger_usersync.py
----------------------------------------------------------------------
diff --git a/ambari-server/src/test/python/stacks/2.2/RANGER/test_ranger_usersync.py b/ambari-server/src/test/python/stacks/2.2/RANGER/test_ranger_usersync.py
index d25d43a..2269d3c 100644
--- a/ambari-server/src/test/python/stacks/2.2/RANGER/test_ranger_usersync.py
+++ b/ambari-server/src/test/python/stacks/2.2/RANGER/test_ranger_usersync.py
@@ -18,6 +18,8 @@ See the License for the specific language governing permissions and
 limitations under the License.
 '''
 
+import sys
+import os
 from stacks.utils.RMFTestCase import RMFTestCase
 from mock.mock import patch
 
@@ -26,6 +28,11 @@ class TestRangerUserSync(RMFTestCase):
   COMMON_SERVICES_PACKAGE_DIR = "RANGER/0.4.0/package"
   STACK_VERSION = "2.2"
 
+  def setUp(self):
+    sys.path.insert(0, os.path.join(os.getcwd(),
+      "../../main/resources/common-services", self.COMMON_SERVICES_PACKAGE_DIR,
+      "scripts"))
+
   @patch("setup_ranger.setup_usersync")
   def test_upgrade(self, setup_usersync_mock):
     self.executeScript(self.COMMON_SERVICES_PACKAGE_DIR + "/scripts/ranger_usersync.py",


Mime
View raw message