def test_step_result_does_not_exist(self):
        r = self.F.ResultFactory.create()
        step = self.F.CaseStepFactory.create()

        self.assertEqual(
            self.result_for(
                r,
                step,
                "{{ stepresult.id }} {{ stepresult.result.id }} "
                "{{ stepresult.step.id }}"),
            "None {0} {1}".format(r.id, step.id)
            )
If the step result does not exist, a new unsaved one is returned.
dataset/ETHPy150Open mozilla/moztrap/tests/view/runtests/templatetags/test_execution.py/StepResultForTest.test_step_result_does_not_exist