tests: fix grid data test for report view
This commit is contained in:
parent
1ec25636df
commit
4b7092bd0a
|
@ -51,8 +51,13 @@ class TestReportViews(WebTestCase):
|
||||||
|
|
||||||
def test_get_grid_data(self):
|
def test_get_grid_data(self):
|
||||||
view = self.make_view()
|
view = self.make_view()
|
||||||
data = view.get_grid_data()
|
providers = dict(self.app.providers)
|
||||||
self.assertIsInstance(data, list)
|
providers['wuttatest'] = MagicMock(report_modules=['tests.views.test_reports'])
|
||||||
|
with patch.object(self.app, 'providers', new=providers):
|
||||||
|
|
||||||
|
data = view.get_grid_data()
|
||||||
|
self.assertIsInstance(data, list)
|
||||||
|
self.assertTrue(data) # 1+ reports
|
||||||
|
|
||||||
def test_normalize_report(self):
|
def test_normalize_report(self):
|
||||||
view = self.make_view()
|
view = self.make_view()
|
||||||
|
|
Loading…
Reference in a new issue