add observer to testplan when running
This commit is contained in:
parent
65aec6550e
commit
d461e5f325
|
@ -128,7 +128,6 @@ public class TestPlanEngine implements TaskCompleteCallback,
|
|||
throws IllegalParameterException {
|
||||
TestPlan testPlan = this.getTestPlanFactory().createATestPlanWithoutId(
|
||||
testPlanBusinessModel, user, testPlanRunId);
|
||||
testPlan.addObserver(this);
|
||||
Logger.getLogger(TestPlanService.class).info(
|
||||
"test plan name:" + testPlan.getName());
|
||||
return this.getTestPlanRepository().attach(testPlan);
|
||||
|
@ -142,6 +141,7 @@ public class TestPlanEngine implements TaskCompleteCallback,
|
|||
+ testPlanId.toString());
|
||||
return;
|
||||
}
|
||||
testPlan.addObserver(this);
|
||||
testPlan.run();
|
||||
this.getTestPlanRepository().attachRunningTestPlan(testPlan);
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue