From 1afece5464520700901cbde19599ac45222ea58f Mon Sep 17 00:00:00 2001 From: BonfaceKilz Date: Sat, 8 May 2021 16:11:20 +0300 Subject: tests: test_gen_menu: Remove app_context initialisation This is no longer required since the global object "Flask.g.db" is no longer coupled to the gen_menu module. --- wqflask/tests/unit/wqflask/api/test_gen_menu.py | 6 ------ 1 file changed, 6 deletions(-) diff --git a/wqflask/tests/unit/wqflask/api/test_gen_menu.py b/wqflask/tests/unit/wqflask/api/test_gen_menu.py index d0cd647a..743b3bde 100644 --- a/wqflask/tests/unit/wqflask/api/test_gen_menu.py +++ b/wqflask/tests/unit/wqflask/api/test_gen_menu.py @@ -2,7 +2,6 @@ import unittest from unittest import mock -from wqflask import app from wqflask.api.gen_menu import gen_dropdown_json from wqflask.api.gen_menu import get_species from wqflask.api.gen_menu import get_groups @@ -18,8 +17,6 @@ class TestGenMenu(unittest.TestCase): """Tests for the gen_menu module""" def setUp(self): - self.app_context = app.app_context() - self.app_context.push() self.test_group = { 'mouse': [ ['H_T1', @@ -70,9 +67,6 @@ class TestGenMenu(unittest.TestCase): } } - def tearDown(self): - self.app_context.pop() - def test_get_species(self): """Test that assertion is raised when dataset and dataset_name are defined""" -- cgit v1.2.3