Explorar o código

[beeswax] Update tests with new re-installable examples

Romain Rigaux %!s(int64=12) %!d(string=hai) anos
pai
achega
da14733621
Modificáronse 1 ficheiros con 4 adicións e 4 borrados
  1. 4 4
      apps/beeswax/src/beeswax/tests.py

+ 4 - 4
apps/beeswax/src/beeswax/tests.py

@@ -824,8 +824,8 @@ for x in sys.stdin:
 
     # Now install it a second time, and expect an error
     resp = self.client.post('/beeswax/install_examples')
-    assert_true('false' in resp.content)
-    assert_true('already installed' in resp.content)
+    assert_true('true' in resp.content)
+    assert_equal('', json.loads(resp.content)['message'])
 
     # First, unset the db entry to allow installation to re-run
     meta = beeswax.models.MetaInstall.get()
@@ -834,8 +834,8 @@ for x in sys.stdin:
 
     # Now it should complain
     resp = self.client.post('/beeswax/install_examples')
-    assert_true('false' in resp.content)
-    assert_true('already exists' in resp.content)
+    assert_true('true' in resp.content)
+    assert_equal('', json.loads(resp.content)['message'])
 
 
   def test_create_table_generation(self):