ambari-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From dmitriu...@apache.org
Subject [2/2] ambari git commit: AMBARI-14018 test_pre_upgrade_restart_ims fails on https://builds.apache.org (dlysnichenko)
Date Mon, 23 Nov 2015 15:41:42 GMT
AMBARI-14018 test_pre_upgrade_restart_ims fails on https://builds.apache.org (dlysnichenko)


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

Branch: refs/heads/trunk
Commit: 2f94036e90014f1d4d2a6484565cbe50e81db736
Parents: 8e7eb7d
Author: Lisnichenko Dmitro <dlysnichenko@hortonworks.com>
Authored: Mon Nov 23 17:41:34 2015 +0200
Committer: Lisnichenko Dmitro <dlysnichenko@hortonworks.com>
Committed: Mon Nov 23 17:41:34 2015 +0200

----------------------------------------------------------------------
 .../python/stacks/2.1/HIVE/test_hive_metastore.py     | 14 ++++++--------
 1 file changed, 6 insertions(+), 8 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/ambari/blob/2f94036e/ambari-server/src/test/python/stacks/2.1/HIVE/test_hive_metastore.py
----------------------------------------------------------------------
diff --git a/ambari-server/src/test/python/stacks/2.1/HIVE/test_hive_metastore.py b/ambari-server/src/test/python/stacks/2.1/HIVE/test_hive_metastore.py
index 63c2449..bdc0fe2 100644
--- a/ambari-server/src/test/python/stacks/2.1/HIVE/test_hive_metastore.py
+++ b/ambari-server/src/test/python/stacks/2.1/HIVE/test_hive_metastore.py
@@ -1,6 +1,6 @@
 #!/usr/bin/env python
 
-'''
+"""
 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
@@ -16,7 +16,8 @@ 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.
-'''
+"""
+
 import json
 import os
 
@@ -29,7 +30,7 @@ from resource_management.libraries.script.script import Script
 class TestHiveMetastore(RMFTestCase):
   COMMON_SERVICES_PACKAGE_DIR = "HIVE/0.12.0.2.0/package"
   STACK_VERSION = "2.0.6"
-  
+
   def test_configure_default(self):
     self.executeScript(self.COMMON_SERVICES_PACKAGE_DIR + "/scripts/hive_metastore.py",
                        classname = "HiveMetastore",
@@ -533,15 +534,12 @@ class TestHiveMetastore(RMFTestCase):
       ('ambari-python-wrap', '/usr/bin/conf-select', 'create-conf-dir', '--package', 'hive',
'--stack-version', '2.3.0.0-1234', '--conf-version', '0'),
        mocks_dict['call'].call_args_list[0][0][0])
 
-
-  @patch("resource_management.core.shell.call")
   @patch.object(Script, "is_hdp_stack_greater_or_equal")
-  def test_pre_upgrade_restart_ims(self, is_hdp_stack_greater_or_equal_mock, call_mock):
+  def test_pre_upgrade_restart_ims(self, is_hdp_stack_greater_or_equal_mock):
     """
     Tests the state of the init_metastore_schema property on update
     """
     is_hdp_stack_greater_or_equal_mock.side_effect = [False, False, False, False, False,
False, True, False, False, False, False, False, False, False]
-
     config_file = self.get_src_folder() + "/test/python/stacks/2.0.6/configs/default.json"
     with open(config_file, "r") as f:
       json_content = json.load(f)
@@ -559,7 +557,7 @@ class TestHiveMetastore(RMFTestCase):
                        config_dict = json_content,
                        hdp_stack_version = self.STACK_VERSION,
                        target = RMFTestCase.TARGET_COMMON_SERVICES,
-                       call_mocks = [(0, None), (0, None)],
+                       call_mocks = [(0, None, ''), (0, None)],
                        mocks_dict = mocks_dict)
 
     self.assertEquals(False, RMFTestCase.env.config["params"]["init_metastore_schema"])


Mime
View raw message