Project

General

Profile

0001-workflows-change-criticality-level-action-to-default.patch

Frédéric Péters, 13 March 2016 03:22 PM

Download (1.33 KB)

View differences:

Subject: [PATCH 1/2] workflows: change criticality level action to default to
 increase (#10280)

 tests/test_workflows.py | 3 ++-
 wcs/wf/criticality.py   | 2 +-
 2 files changed, 3 insertions(+), 2 deletions(-)
tests/test_workflows.py
986 986

  
987 987
    formdata = formdef.data_class()()
988 988
    item.perform(formdata)
989
    assert not formdata.criticality_level
989
    assert formdata.get_criticality_level_object().name == 'yellow'
990 990

  
991
    formdata = formdef.data_class()()
991 992
    item.mode = MODE_INC
992 993
    item.perform(formdata)
993 994
    assert formdata.get_criticality_level_object().name == 'yellow'
wcs/wf/criticality.py
27 27
    description = N_('Modify Criticality')
28 28
    key = 'modify_criticality'
29 29

  
30
    mode = None
30
    mode = MODE_INC
31 31
    absolute_value = None
32 32

  
33 33
    def get_parameters(self):
34
-