From 9d63b8d4927633a3bdc4b6009ad6e178c5ee45da Mon Sep 17 00:00:00 2001 From: Christophe Simonis Date: Sun, 21 Aug 2016 22:20:36 +0200 Subject: [PATCH] [FIX] website_forum: ensure demo user have enough karma to post non-pending questions --- addons/website_forum/tests/test_forum_process.py | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/addons/website_forum/tests/test_forum_process.py b/addons/website_forum/tests/test_forum_process.py index ef8b290a075..d580a79c428 100644 --- a/addons/website_forum/tests/test_forum_process.py +++ b/addons/website_forum/tests/test_forum_process.py @@ -10,4 +10,9 @@ class TestUi(odoo.tests.HttpCase): self.phantom_js("/", "odoo.__DEBUG__.services['web_tour.tour'].run('question')", "odoo.__DEBUG__.services['web_tour.tour'].tours.question", login="admin") def test_02_demo_question(self): + with self.cursor() as test_cr: + env = self.env(cr=test_cr) + forum = env.ref('website_forum.forum_help') + demo = env.ref('base.user_demo') + demo.karma = forum.karma_post + 1 self.phantom_js("/", "odoo.__DEBUG__.services['web.Tour'].run('forum_question', 'test')", "odoo.__DEBUG__.services['web.Tour'].tours.forum_question", login="demo")