Mercurial > libervia-backend
comparison src/test/test_plugin_xep_0277.py @ 1910:55440ee00905
test: update some tests
author | souliane <souliane@mailoo.org> |
---|---|
date | Fri, 11 Mar 2016 17:42:56 +0100 |
parents | d17772b0fe22 |
children | ee1125fffba8 |
comparison
equal
deleted
inserted
replaced
1909:0681d69cbe0a | 1910:55440ee00905 |
---|---|
19 | 19 |
20 """ Plugin XEP-0277 tests """ | 20 """ Plugin XEP-0277 tests """ |
21 | 21 |
22 from sat.test import helpers | 22 from sat.test import helpers |
23 from sat.plugins import plugin_xep_0277 | 23 from sat.plugins import plugin_xep_0277 |
24 from sat.plugins import plugin_xep_0060 | |
24 from sat.plugins import plugin_misc_text_syntaxes | 25 from sat.plugins import plugin_misc_text_syntaxes |
25 from sat.tools.xml_tools import ElementParser | 26 from sat.tools.xml_tools import ElementParser |
26 | 27 |
27 | 28 |
28 class XEP_0277Test(helpers.SatTestCase): | 29 class XEP_0277Test(helpers.SatTestCase): |
67 def __init__(self, host): | 68 def __init__(self, host): |
68 pass | 69 pass |
69 | 70 |
70 def addPEPEvent(self, *args): | 71 def addPEPEvent(self, *args): |
71 pass | 72 pass |
73 self.host.plugins["XEP-0060"] = plugin_xep_0060.XEP_0060(self.host) | |
72 self.host.plugins["XEP-0163"] = XEP_0163(self.host) | 74 self.host.plugins["XEP-0163"] = XEP_0163(self.host) |
75 reload(plugin_misc_text_syntaxes) # reload the plugin to avoid conflict error | |
73 self.host.plugins["TEXT-SYNTAXES"] = plugin_misc_text_syntaxes.TextSyntaxes(self.host) | 76 self.host.plugins["TEXT-SYNTAXES"] = plugin_misc_text_syntaxes.TextSyntaxes(self.host) |
74 self.plugin = plugin_xep_0277.XEP_0277(self.host) | 77 self.plugin = plugin_xep_0277.XEP_0277(self.host) |
75 | 78 |
76 def test_item2mbdata_1(self): | 79 def test_item2mbdata_1(self): |
77 expected = {'id': 'c745a688-9b02-11e3-a1a3-c0143dd4fe51', | 80 expected = {'id': 'c745a688-9b02-11e3-a1a3-c0143dd4fe51', |