]> git.argeo.org Git - gpl/argeo-slc.git/blob - org.argeo.slc.core/src/main/java/org/argeo/slc/core/test/TestRunDescriptor.java
Updates required by deploy
[gpl/argeo-slc.git] / org.argeo.slc.core / src / main / java / org / argeo / slc / core / test / TestRunDescriptor.java
1 package org.argeo.slc.core.test;
2
3 import org.argeo.slc.core.deploy.DeployedSystem;
4 import org.argeo.slc.core.process.SlcExecution;
5
6 public class TestRunDescriptor {
7 private String testRunUuid;
8 private String slcExecutionUuid;
9 private String slcExecutionStepUuid;
10 private String testResultUuid;
11 private String deployedSytemId;
12
13 public TestRunDescriptor() {
14
15 }
16
17 public TestRunDescriptor(TestRun testRun) {
18 testRunUuid = testRun.getUuid();
19
20 if (testRun.getTestResult() != null)
21 testResultUuid = testRun.<TestResult> getTestResult().getUuid();
22
23 if (testRun.getDeployedSystem() != null)
24 deployedSytemId = testRun.<DeployedSystem> getDeployedSystem()
25 .getDeployedSystemId();
26
27 if (testRun instanceof SimpleTestRun) {
28 slcExecutionUuid = ((SimpleTestRun) testRun).getSlcExecutionUuid();
29 slcExecutionStepUuid = ((SimpleTestRun) testRun)
30 .getSlcExecutionStepUuid();
31 }
32 }
33
34 public String getTestRunUuid() {
35 return testRunUuid;
36 }
37
38 public void setTestRunUuid(String testRunUuid) {
39 this.testRunUuid = testRunUuid;
40 }
41
42 public String getSlcExecutionUuid() {
43 return slcExecutionUuid;
44 }
45
46 public void setSlcExecutionUuid(String slcExecutionUuid) {
47 this.slcExecutionUuid = slcExecutionUuid;
48 }
49
50 public String getSlcExecutionStepUuid() {
51 return slcExecutionStepUuid;
52 }
53
54 public void setSlcExecutionStepUuid(String slcExecutionStepUuid) {
55 this.slcExecutionStepUuid = slcExecutionStepUuid;
56 }
57
58 public String getTestResultUuid() {
59 return testResultUuid;
60 }
61
62 public void setTestResultUuid(String testResultUuid) {
63 this.testResultUuid = testResultUuid;
64 }
65
66 public String getDeployedSytemId() {
67 return deployedSytemId;
68 }
69
70 public void setDeployedSytemId(String deploymentId) {
71 this.deployedSytemId = deploymentId;
72 }
73
74 @Override
75 public boolean equals(Object obj) {
76 if (obj instanceof TestRunDescriptor) {
77 return getTestRunUuid().equals(
78 ((TestRunDescriptor) obj).getTestRunUuid());
79 }
80 return false;
81 }
82 }