cubicweb/hooks/test/unittest_syncsources.py
branch3.25
changeset 12153 0ff0aff4413d
parent 12152 f34d18d0603f
child 12154 0cf35ffde0e4
--- a/cubicweb/hooks/test/unittest_syncsources.py	Wed Apr 12 16:07:25 2017 +0200
+++ b/cubicweb/hooks/test/unittest_syncsources.py	Wed Apr 12 16:10:57 2017 +0200
@@ -26,8 +26,15 @@
         with self.admin_access.cnx() as cnx:
             source = cnx.find('CWSource').one()
 
-            with self.assertRaises(ValidationError):
+            with self.assertRaises(ValidationError) as cm:
+                source.cw_set(url=u'whatever')
+            self.assertIn("Configuration of the system source goes to the 'sources' file",
+                          str(cm.exception))
+
+            with self.assertRaises(ValidationError) as cm:
                 source.cw_set(config=u'whatever')
+            self.assertIn("Configuration of the system source goes to the 'sources' file",
+                          str(cm.exception))
 
 
 if __name__ == '__main__':