From 94356ff638eec3ec27dbddc0ea814a90879bd4b5 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?C=C3=A9dric=20Krier?= Date: Tue, 27 Jan 2015 18:14:20 +0100 Subject: [PATCH] Add check for default model access When group access exists, a default model access should be defined otherwise all access are given to non group users. issue4485 review5941002 --- setup.py | 2 ++ tests/__init__.py | 6 ++++++ tests/test_stock_supply_forecast.py | 17 +++++++++++++++++ 3 files changed, 25 insertions(+) create mode 100644 tests/__init__.py create mode 100644 tests/test_stock_supply_forecast.py diff --git a/setup.py b/setup.py index 32f2a38f79..f3b872bdb1 100644 --- a/setup.py +++ b/setup.py @@ -94,4 +94,6 @@ setup(name=name, [trytond.modules] stock_supply_forecast = trytond.modules.stock_supply_forecast """, + test_suite='tests', + test_loader='trytond.test_loader:Loader', ) diff --git a/tests/__init__.py b/tests/__init__.py new file mode 100644 index 0000000000..b7b196724a --- /dev/null +++ b/tests/__init__.py @@ -0,0 +1,6 @@ +# This file is part of Tryton. The COPYRIGHT file at the top level of +# this repository contains the full copyright notices and license terms. + +from .test_stock_supply_forecast import suite + +__all__ = ['suite'] diff --git a/tests/test_stock_supply_forecast.py b/tests/test_stock_supply_forecast.py new file mode 100644 index 0000000000..45de8a9b8e --- /dev/null +++ b/tests/test_stock_supply_forecast.py @@ -0,0 +1,17 @@ +# This file is part of Tryton. The COPYRIGHT file at the top level of +# this repository contains the full copyright notices and license terms. +import unittest +import trytond.tests.test_tryton +from trytond.tests.test_tryton import ModuleTestCase + + +class StockSupplyForecastTestCase(ModuleTestCase): + 'Test StockSupplyForecast module' + module = 'stock_supply_forecast' + + +def suite(): + suite = trytond.tests.test_tryton.suite() + suite.addTests(unittest.TestLoader().loadTestsFromTestCase( + StockSupplyForecastTestCase)) + return suite