You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@ambari.apache.org by jo...@apache.org on 2014/09/19 19:19:26 UTC
[18/29] git commit: AMBARI-7401. Ambari Unit Tests failing on
Jenkins.(vbrodetskyi)
AMBARI-7401. Ambari Unit Tests failing on Jenkins.(vbrodetskyi)
Project: http://git-wip-us.apache.org/repos/asf/ambari/repo
Commit: http://git-wip-us.apache.org/repos/asf/ambari/commit/0eb3937c
Tree: http://git-wip-us.apache.org/repos/asf/ambari/tree/0eb3937c
Diff: http://git-wip-us.apache.org/repos/asf/ambari/diff/0eb3937c
Branch: refs/heads/branch-alerts-dev
Commit: 0eb3937c208ac650725059356ec909effc367534
Parents: 5c48015
Author: Vitaly Brodetskyi <vb...@hortonworks.com>
Authored: Fri Sep 19 13:41:24 2014 +0300
Committer: Vitaly Brodetskyi <vb...@hortonworks.com>
Committed: Fri Sep 19 13:41:24 2014 +0300
----------------------------------------------------------------------
ambari-agent/src/test/python/ambari_agent/TestController.py | 4 ++--
.../test/python/ambari_agent/TestCustomServiceOrchestrator.py | 3 ++-
2 files changed, 4 insertions(+), 3 deletions(-)
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/ambari/blob/0eb3937c/ambari-agent/src/test/python/ambari_agent/TestController.py
----------------------------------------------------------------------
diff --git a/ambari-agent/src/test/python/ambari_agent/TestController.py b/ambari-agent/src/test/python/ambari_agent/TestController.py
index ad8303f..7ef64cc 100644
--- a/ambari-agent/src/test/python/ambari_agent/TestController.py
+++ b/ambari-agent/src/test/python/ambari_agent/TestController.py
@@ -364,7 +364,7 @@ class TestController(unittest.TestCase):
self.fail("Should throw exception!")
except IOError, e: # Expected
self.assertEquals('Response parsing failed! Request data: ' + data +
- '; Response: {invalid_object}', e.message)
+ '; Response: {invalid_object}', str(e))
exceptionMessage = "Connection Refused"
conMock.request.side_effect = Exception(exceptionMessage)
@@ -373,7 +373,7 @@ class TestController(unittest.TestCase):
self.fail("Should throw exception!")
except IOError, e: # Expected
self.assertEquals('Request to ' + url + ' failed due to ' +
- exceptionMessage, e.message)
+ exceptionMessage, str(e))
@patch.object(threading._Event, "wait")
http://git-wip-us.apache.org/repos/asf/ambari/blob/0eb3937c/ambari-agent/src/test/python/ambari_agent/TestCustomServiceOrchestrator.py
----------------------------------------------------------------------
diff --git a/ambari-agent/src/test/python/ambari_agent/TestCustomServiceOrchestrator.py b/ambari-agent/src/test/python/ambari_agent/TestCustomServiceOrchestrator.py
index 92791e2..6a61c0d 100644
--- a/ambari-agent/src/test/python/ambari_agent/TestCustomServiceOrchestrator.py
+++ b/ambari-agent/src/test/python/ambari_agent/TestCustomServiceOrchestrator.py
@@ -486,7 +486,8 @@ class TestCustomServiceOrchestrator(TestCase):
'taskId' : '13',
'roleCommand': 'ACTIONEXECUTE',
'commandType': 'BACKGROUND_EXECUTION_COMMAND',
- '__handle' : BackgroundCommandExecutionHandle(None,13,MagicMock(), MagicMock())
+ '__handle': BackgroundCommandExecutionHandle({'taskId': '13'}, 13,
+ MagicMock(), MagicMock())
}
dummy_controller = MagicMock()
orchestrator = CustomServiceOrchestrator(self.config, dummy_controller)