sobjects/test/unittest_notification.py
changeset 2773 b2530e3e0afb
parent 2650 18aec79ec3a3
child 2968 0e3460341023
--- a/sobjects/test/unittest_notification.py	Tue Aug 11 17:04:59 2009 +0200
+++ b/sobjects/test/unittest_notification.py	Tue Aug 11 17:13:32 2009 +0200
@@ -9,7 +9,7 @@
 from socket import gethostname
 
 from logilab.common.testlib import unittest_main, TestCase
-from cubicweb.devtools.apptest import EnvBasedTC
+from cubicweb.devtools.testlib import CubicWebTC
 
 from cubicweb.sobjects.notification import construct_message_id, parse_message_id
 
@@ -48,7 +48,7 @@
             self.assertNotEquals(msgid1, '<@testapp.%s>' % gethostname())
 
 
-class RecipientsFinderTC(EnvBasedTC):
+class RecipientsFinderTC(CubicWebTC):
     def test(self):
         urset = self.execute('CWUser X WHERE X login "admin"')
         self.execute('INSERT EmailAddress X: X address "admin@logilab.fr", U primary_email X '
@@ -67,10 +67,10 @@
         self.assertEquals(finder.recipients(), [('abcd@logilab.fr', 'en'), ('efgh@logilab.fr', 'en')])
 
 
-class StatusChangeViewsTC(EnvBasedTC):
+class StatusChangeViewsTC(CubicWebTC):
 
     def test_status_change_view(self):
-        req = self.session()
+        req = self.session
         u = self.create_user('toto', req=req)
         assert u.req
         assert u.rset