Commit dbe2055b authored by Romain Courteaud's avatar Romain Courteaud

Can not destroy from draft state.

parent 889793a2
...@@ -319,6 +319,7 @@ portal_workflow.doActionFor(context, action='edit_action', comment='Visited by D ...@@ -319,6 +319,7 @@ portal_workflow.doActionFor(context, action='edit_action', comment='Visited by D
shared=False, shared=False,
) )
subscription.requestStart(**request_kw)
subscription.converge() subscription.converge()
self.assertEqual(subscription.getCausalityState(), 'solved') self.assertEqual(subscription.getCausalityState(), 'solved')
subscription.requestDestroy(**request_kw) subscription.requestDestroy(**request_kw)
...@@ -333,7 +334,6 @@ portal_workflow.doActionFor(context, action='edit_action', comment='Visited by D ...@@ -333,7 +334,6 @@ portal_workflow.doActionFor(context, action='edit_action', comment='Visited by D
) )
subscription.validate() subscription.validate()
self.assertEqual(subscription.getCausalityState(), 'diverged')
request_kw = dict( request_kw = dict(
software_release='http://example.org', software_release='http://example.org',
...@@ -343,5 +343,8 @@ portal_workflow.doActionFor(context, action='edit_action', comment='Visited by D ...@@ -343,5 +343,8 @@ portal_workflow.doActionFor(context, action='edit_action', comment='Visited by D
shared=False, shared=False,
) )
subscription.requestStart(**request_kw)
self.assertEqual(subscription.getCausalityState(), 'diverged')
subscription.requestDestroy(**request_kw) subscription.requestDestroy(**request_kw)
self.assertEqual(subscription.getCausalityState(), 'diverged') self.assertEqual(subscription.getCausalityState(), 'diverged')
235 236
\ No newline at end of file \ No newline at end of file
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment