[IMP] move testing of xml conversion alongside test data to ensure tests only run if module on addons_path/loaded
bzr revid: xmo@openerp.com-20130429122317-yzv4prie9hc7f7l6
This commit is contained in:
parent
45bb6ec7f1
commit
2e8c9a48e1
|
@ -21,7 +21,6 @@ import test_osv
|
|||
import test_translate
|
||||
import test_uninstall
|
||||
import test_view_validation
|
||||
import test_convert
|
||||
# This need a change in `oe run-tests` to only run fast_suite + checks by default.
|
||||
# import test_xmlrpc
|
||||
|
||||
|
@ -42,7 +41,6 @@ checks = [
|
|||
test_misc,
|
||||
test_osv,
|
||||
test_translate,
|
||||
test_convert,
|
||||
]
|
||||
|
||||
# vim:expandtab:smartindent:tabstop=4:softtabstop=4:shiftwidth=4:
|
||||
|
|
|
@ -1 +0,0 @@
|
|||
# -*- coding: utf-8 -*-
|
|
@ -0,0 +1,6 @@
|
|||
# -*- coding: utf-8 -*-
|
||||
from . import test_convert
|
||||
|
||||
checks = [
|
||||
test_convert
|
||||
]
|
|
@ -3,7 +3,7 @@ import unittest2
|
|||
from lxml import etree as ET
|
||||
from lxml.builder import E
|
||||
|
||||
from . import common
|
||||
from openerp.tests import common
|
||||
|
||||
from openerp.tools.convert import _eval_xml
|
||||
|
|
@ -165,7 +165,8 @@ def _eval_xml(self, node, pool, cr, uid, idref, context=None):
|
|||
from ..modules import module
|
||||
path = node.text.strip()
|
||||
if not module.get_module_resource(self.module, path):
|
||||
raise IOError("No such file or directory: '%s'" % path)
|
||||
raise IOError("No such file or directory: '%s' in %s" % (
|
||||
path, self.module))
|
||||
return '%s,%s' % (self.module, path)
|
||||
if t in ('char', 'int', 'float'):
|
||||
d = node.text
|
||||
|
|
Loading…
Reference in New Issue