-
Notifications
You must be signed in to change notification settings - Fork 21
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
4 changed files
with
179 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,57 @@ | ||
package org.alm.model; | ||
|
||
import javax.xml.bind.annotation.XmlRootElement; | ||
|
||
@XmlRootElement | ||
public class TestSet extends Entity | ||
{ | ||
public TestSet(Entity entity) | ||
{ | ||
super(entity); | ||
} | ||
|
||
public TestSet() | ||
{ | ||
type("test-set"); | ||
} | ||
|
||
public String status() | ||
{ | ||
return fieldValue("status"); | ||
} | ||
|
||
public void status(String value) | ||
{ | ||
fieldValue("status", value); | ||
} | ||
|
||
public String subtypeId() | ||
{ | ||
return fieldValue("subtype-id"); | ||
} | ||
|
||
public void subtypeId(String value) | ||
{ | ||
fieldValue("subtype-id", value); | ||
} | ||
|
||
public String comment() | ||
{ | ||
return fieldValue("comment"); | ||
} | ||
|
||
public void comment(String value) | ||
{ | ||
fieldValue("comment", value); | ||
} | ||
|
||
public String linkage() | ||
{ | ||
return fieldValue("linkage"); | ||
} | ||
|
||
public void linkage(String value) | ||
{ | ||
fieldValue("linkage", value); | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,64 @@ | ||
package org.alm.model; | ||
|
||
import org.testng.Assert; | ||
import org.testng.annotations.BeforeMethod; | ||
import org.testng.annotations.Test; | ||
|
||
public class TestTestSet | ||
{ | ||
TestSet testSet; | ||
|
||
@BeforeMethod | ||
public void initTestSetEntity() | ||
{ | ||
testSet = new TestSet(); | ||
} | ||
|
||
@Test(groups = { "test-set" }) | ||
public void type() | ||
{ | ||
Assert.assertEquals(testSet.type(), "test-set"); | ||
} | ||
|
||
@Test(groups = { "test-set" }) | ||
public void status() | ||
{ | ||
testSet.status("Open"); | ||
|
||
Assert.assertEquals(testSet.status(), "Open"); | ||
} | ||
|
||
@Test(groups = { "test-set" }) | ||
public void subtypeId() | ||
{ | ||
testSet.subtypeId("101F3974-AD91-49d8-97EF-B3DEC6F0AEA3"); | ||
|
||
Assert.assertEquals(testSet.subtypeId(), "101F3974-AD91-49d8-97EF-B3DEC6F0AEA3"); | ||
} | ||
|
||
@Test(groups = { "test-set" }) | ||
public void comment() | ||
{ | ||
testSet.comment("<html>" | ||
+ "<body>" | ||
+ "<div align=\"left\"><font face=\"Arial\"><span style=\"font-size:8pt\">" | ||
+ "For running tests on Mansfield Park planning tests</span></font></div>" | ||
+ "</body>" | ||
+ "</html>"); | ||
|
||
Assert.assertEquals(testSet.comment(), "<html>" | ||
+ "<body>" | ||
+ "<div align=\"left\"><font face=\"Arial\"><span style=\"font-size:8pt\">" | ||
+ "For running tests on Mansfield Park planning tests</span></font></div>" | ||
+ "</body>" | ||
+ "</html>"); | ||
} | ||
|
||
@Test(groups = { "test-set" }) | ||
public void linkage() | ||
{ | ||
testSet.linkage("N"); | ||
|
||
Assert.assertEquals(testSet.linkage(), "N"); | ||
} | ||
} |