From 3091ce6548c7550cd8f0ac44872eb20bd8a56cbd Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?C=C3=A9dric=20Krier?= Date: Wed, 18 Oct 2017 14:59:18 +0200 Subject: [PATCH] Add test for set work state at creation issue6720 review40751004 --- tests/scenario_production_work.rst | 15 +++++++++++++++ 1 file changed, 15 insertions(+) diff --git a/tests/scenario_production_work.rst b/tests/scenario_production_work.rst index a22d36909a..9082bf0a39 100644 --- a/tests/scenario_production_work.rst +++ b/tests/scenario_production_work.rst @@ -226,6 +226,21 @@ Run works:: >>> work2.state u'finished' +Add an extra work:: + + >>> work2b = production.works.new() + >>> work2b.operation = operation2 + >>> work2b.work_center = center2 + >>> production.save() + >>> work2b = production.works[-1] + + >>> work2b.state + u'draft' + +And delete the extra work:: + + >>> work2b.delete() + Check production cost:: >>> production.reload()