[test] stop using TestCase.set_description
authorJulien Cristau <julien.cristau@logilab.fr>
Thu, 18 Feb 2016 09:23:18 +0100
changeset 11165 c6fe858f6b90
parent 11164 e3fa26bd9ce0
child 11166 81fce01b4cc0
[test] stop using TestCase.set_description It's a lgc-ism.
cubicweb/dataimport/test/test_stores.py
cubicweb/devtools/qunit.py
cubicweb/devtools/testlib.py
--- a/cubicweb/dataimport/test/test_stores.py	Thu Feb 18 09:20:57 2016 +0100
+++ b/cubicweb/dataimport/test/test_stores.py	Thu Feb 18 09:23:18 2016 +0100
@@ -41,7 +41,6 @@
             self.assertEqual(1, len(users))
             self.assertEqual(group_eid, groups.one().eid)
             # Check data update
-            self.set_description('Check data update')
             store.prepare_update_entity('CWGroup', group_eid, name=u'new_grp')
             cnx.commit()
             group = cnx.execute('CWGroup X WHERE X name "grp"')
--- a/cubicweb/devtools/qunit.py	Thu Feb 18 09:20:57 2016 +0100
+++ b/cubicweb/devtools/qunit.py	Thu Feb 18 09:23:18 2016 +0100
@@ -136,7 +136,6 @@
             try:
                 result, test_name, msg = self.test_queue.get(timeout=timeout)
                 test_name = '%s (%s)' % (test_name, test_file)
-                self.set_description(test_name)
                 if result is None:
                     break
                 test_count += 1
--- a/cubicweb/devtools/testlib.py	Thu Feb 18 09:20:57 2016 +0100
+++ b/cubicweb/devtools/testlib.py	Thu Feb 18 09:23:18 2016 +0100
@@ -924,16 +924,6 @@
         req.form['vid'] = vid
         viewsreg = self.vreg['views']
         view = viewsreg.select(vid, req, rset=rset, **kwargs)
-        # set explicit test description
-        if rset is not None:
-            # coerce to "bytes" on py2 because the description will be sent to
-            # sys.stdout/stderr which takes "bytes" on py2 and "unicode" on py3
-            rql = str(rset.printable_rql())
-            self.set_description("testing vid=%s defined in %s with (%s)" % (
-                vid, view.__module__, rql))
-        else:
-            self.set_description("testing vid=%s defined in %s without rset" % (
-                vid, view.__module__))
         if template is None:  # raw view testing, no template
             viewfunc = view.render
         else: