- # add step of process p2 as explicit sub-step to p1's second (p3)
- # top-level step
- add_step(p1, steps_p1, (None, p3.id_, 2), 7)
- p1_dict[2].steps[7] = ProcessStepsNode(p3, 2, True, {}, False)
- # import pprint
- # pprint.pp(p1.get_steps(self.db_conn, None))
- # pprint.pp(p1_dict)
+ # # add step of process p3 as explicit sub-step to p1's first sub-step,
+ # # expect it to eliminate implicit p3 sub-step
+ # s_p3_to_p1_first_explicit = ProcessStep(None, p1.id_, p3.id_,
+ # s_p2_to_p1.id_)
+ # p1_dict[1].steps = {7: ProcessStepsNode(p3, 1, True, {}, False)}
+ # p1_dict[2].steps[4].steps[3].seen = False
+ # steps_p1 += [s_p3_to_p1_first_explicit]
+ # p1.set_steps(self.db_conn, steps_p1)
+ # self.assertEqual(p1.get_steps(self.db_conn, None), p1_dict)
+ # ensure implicit steps non-top explicit steps are shown
+ s_p3_to_p2_first = ProcessStep(None, p2.id_, p3.id_, s_p3_to_p2.id_)
+ steps_p2 += [s_p3_to_p2_first]
+ p2.set_steps(self.db_conn, steps_p2)
+ p1_dict[1].steps[3].steps[7] = ProcessStepsNode(p3, 3, False, {},
+ False)
+ p1_dict[2].steps[4].steps[3].steps[7] = ProcessStepsNode(p3, 3, False,
+ {}, True)