[FIX] pos_restaurant: make test post install
There was ahack that was setting the module pos_restaurant to installed, which is not necessary as we should simply put the test in post_install
This commit is contained in:
@@ -3,9 +3,8 @@
|
||||
|
||||
import odoo.tests
|
||||
|
||||
|
||||
@odoo.tests.tagged('post_install', '-at_install')
|
||||
class TestFrontend(odoo.tests.HttpCase):
|
||||
|
||||
def test_01_pos_restaurant(self):
|
||||
env = self.env(user=self.env.ref('base.user_admin'))
|
||||
account_obj = env['account.account']
|
||||
@@ -57,13 +56,6 @@ class TestFrontend(odoo.tests.HttpCase):
|
||||
|
||||
pos_config.open_session_cb()
|
||||
|
||||
# needed because tests are run before the module is marked as
|
||||
# installed. In js web will only load qweb coming from modules
|
||||
# that are returned by the backend in module_boot. Without
|
||||
# this you end up with js, css but no qweb.
|
||||
env['ir.module.module'].search([('name', '=', 'pos_restaurant')], limit=1).state = 'installed'
|
||||
|
||||
|
||||
self.start_tour("/pos/web?config_id=%d" % pos_config.id, 'pos_restaurant_sync', login="admin")
|
||||
|
||||
self.assertEqual(1, env['pos.order'].search_count([('amount_total', '=', 4.4), ('state', '=', 'draft')]))
|
||||
|
||||
Reference in New Issue
Block a user