summaryrefslogtreecommitdiffstats
path: root/windriver/titanium_cloud/vesagent/tests/tests_vespublish.py
diff options
context:
space:
mode:
authorXiaohua Zhang <xiaohua.zhang@windriver.com>2018-11-27 10:31:54 +0000
committerXiaohua Zhang <xiaohua.zhang@windriver.com>2018-11-27 10:31:54 +0000
commitf8c71ac2d1a764c953f5c8cf513aa8d3f9810578 (patch)
tree1fdd124fc76e4d35c2880dee0e9d52e9b0826487 /windriver/titanium_cloud/vesagent/tests/tests_vespublish.py
parent78ead3c00e16cf9e4fd24535a925d3766c6f6aa8 (diff)
Fix pep8 errors in windriver plugin
Fix errors in vesagent Change-Id: I9cb0afda7a17a08246fcee8439e1ef2775609948 Issue-ID: MULTICLOUD-420 Signed-off-by: Xiaohua Zhang <xiaohua.zhang@windriver.com>
Diffstat (limited to 'windriver/titanium_cloud/vesagent/tests/tests_vespublish.py')
-rw-r--r--windriver/titanium_cloud/vesagent/tests/tests_vespublish.py22
1 files changed, 11 insertions, 11 deletions
diff --git a/windriver/titanium_cloud/vesagent/tests/tests_vespublish.py b/windriver/titanium_cloud/vesagent/tests/tests_vespublish.py
index 0178aaed..64ea7d00 100644
--- a/windriver/titanium_cloud/vesagent/tests/tests_vespublish.py
+++ b/windriver/titanium_cloud/vesagent/tests/tests_vespublish.py
@@ -15,17 +15,19 @@
import mock
import unittest
-import json
+# import json
import urllib2
from titanium_cloud.vesagent import vespublish
MOCK_VESENDPOINT = {
- "endpoint" : "MOCKED_VES_COLLECTOR_EP1",
- "username" : "MOCKED_VES_COLLECTOR_USER1",
- "password" : "MOCKED_VES_COLLECTOR_PASSWD1",
+ "endpoint": "MOCKED_VES_COLLECTOR_EP1",
+ "username": "MOCKED_VES_COLLECTOR_USER1",
+ "password": "MOCKED_VES_COLLECTOR_PASSWD1",
}
-MOCK_VESPUBLISH_EVENT1 = [{"name":"event1"}]
+
+MOCK_VESPUBLISH_EVENT1 = [{"name": "event1"}]
+
class VespublishTest(unittest.TestCase):
def setUp(self):
@@ -39,16 +41,14 @@ class VespublishTest(unittest.TestCase):
def test_publishAnyEventToVES(self, mock_Request, mock_urlopen):
mock_request = mock.Mock()
- mock_Request.side_effect= [
+ mock_Request.side_effect = [
mock_request
- ]
+ ]
mock_response = mock.Mock(["read"])
mock_response.read.return_value = "MOCKED_VESPUBLISH_RESPONSE_MESSAGE"
- mock_urlopen.side_effect= [
+ mock_urlopen.side_effect = [
mock_response
- ]
+ ]
vespublish.publishAnyEventToVES(MOCK_VESENDPOINT, MOCK_VESPUBLISH_EVENT1)
-
- pass