[test] avoid using a deprecated feature of yams
handle_file() now require a module name (yams@d9120d7)
--- a/cubicweb/test/unittest_schema.py Tue May 12 22:14:24 2015 +0200
+++ b/cubicweb/test/unittest_schema.py Fri Jan 20 09:55:08 2017 +0100
@@ -17,7 +17,7 @@
# with CubicWeb. If not, see <http://www.gnu.org/licenses/>.
"""unit tests for module cubicweb.schema"""
-from os.path import join, dirname
+from os.path import join, dirname, splitext
from logilab.common.testlib import TestCase, unittest_main
@@ -402,7 +402,8 @@
self.loader.post_build_callbacks = []
def _test(self, schemafile, msg):
- self.loader.handle_file(join(DATADIR, schemafile), None)
+ self.loader.handle_file(join(DATADIR, schemafile),
+ splitext(schemafile)[0])
sch = self.loader.schemacls('toto')
with self.assertRaises(BadSchemaDefinition) as cm:
fill_schema(sch, self.loader.defined, False)