public class AssertionsImpl extends Object implements Assertions
Assertions| Constructor and Description |
|---|
AssertionsImpl(net.sourceforge.jwebunit.WebTester tester,
JIRAEnvironmentData environmentData,
Navigation navigation,
LocatorFactory locator,
Backdoor backdoor) |
| Modifier and Type | Method and Description |
|---|---|
void |
assertEquals(String failureMessage,
List expected,
List actual)
Elaboration of assertEquals for lists with nicer messages.
|
void |
assertHttpStatusCode(com.atlassian.httpclient.api.HttpStatus code)
Check that the last response returned the provided HTTP status code.
|
void |
assertLastChangeHistoryRecords(String issueKey,
ExpectedChangeHistoryRecord expectedChangeHistoryRecord)
Useful to check that a particular change history item exists for a given issue.
|
void |
assertLastChangeHistoryRecords(String issueKey,
List expectedChangeHistoryRecords)
Useful to check that a number of change history items exist for a given issue.
|
void |
assertNewestChangeHistoryRecord(String issueKey,
String authorName,
List<ExpectedChangeHistoryItem> expectedChangeHistoryItems)
Useful to check if newest change history entry exists with proper values.
|
void |
assertNodeByIdDoesNotExist(String id)
Asserts that a given node does not exists
|
void |
assertNodeByIdDoesNotHaveText(String id,
String textToTest)
Asserts that a given node exists but does not contain the given text
|
void |
assertNodeByIdEquals(String id,
String textToTest)
Asserts that a given node exactly equals the given text
|
void |
assertNodeByIdExists(String id)
Asserts that a given node exists
|
void |
assertNodeByIdHasText(String id,
String textToTest)
Asserts that a given node contains the given text
|
void |
assertNodeDoesNotExist(Locator locator)
Asserts that a given node does not exists
|
void |
assertNodeDoesNotExist(String xpath)
Asserts that a node does not exist under the xpath expression given
|
void |
assertNodeDoesNotHaveText(Locator locator,
String textToTest)
Asserts that a given node exists but does not contain the given text
|
void |
assertNodeDoesNotHaveText(String xpath,
String textToTest)
Asserts that a node under the xpath expression given does not contain the given text
|
void |
assertNodeEquals(Locator locator,
String textToTest)
Asserts that a given node exactly equals the given text
|
void |
assertNodeExists(Locator locator)
Asserts that a given node exists
|
void |
assertNodeExists(String xpath)
Asserts that a node exists under the xpath expression given
|
void |
assertNodeHasText(Locator locator,
String textToTest)
Asserts that a given node contains the given text
|
void |
assertNodeHasText(String xpath,
String textToTest)
Asserts that a node under the xpath expression given contains the given text
|
void |
assertProfileLinkPresent(String id,
String linkText)
Checks that a profile link with the given ID and link Text exists on the page.
|
void |
assertSubmitButtonPresentWithText(String buttonId,
String buttonText)
Check that the button with the id provided has the text provided as its value.
|
CommentAssertions |
comments(Iterable<String> comments)
Returns an object that can be used to make assertions on a specified group of comments.
|
CommentAssertions |
comments(String... comments)
Returns an object that can be used to make assertions on a specified group of comments.
|
JiraFormAssertions |
forms()
Form assertions.
|
DashboardAssertions |
getDashboardAssertions() |
IssueNavigatorAssertions |
getIssueNavigatorAssertions()
Return an object that can be used to make assertions about the navigator.
|
JiraFormAssertions |
getJiraFormAssertions() |
JiraMessageAssertions |
getJiraMessageAssertions() |
LabelAssertions |
getLabelAssertions() |
LinkAssertions |
getLinkAssertions() |
ProjectFieldsAssertions |
getProjectFieldsAssertions() |
RequestAssertions |
getRequestAssertions() |
SidebarAssertions |
getSidebarAssertions() |
TableAssertions |
getTableAssertions() |
TextAssertions |
getTextAssertions() |
URLAssertions |
getURLAssertions() |
UserAssertions |
getUserAssertions() |
ViewIssueAssertions |
getViewIssueAssertions()
Returns an object that can be used to make assertions on the "View Issue" page.
|
HTMLAssertions |
html()
HTML assertions.
|
LinkAssertions |
link()
Link assertions.
|
PluginAssertions |
plugins()
Returns an object that can be used to make assertions about P2 plugins.
|
TextAssertions |
text()
Text assertions.
|
@Inject
public AssertionsImpl(net.sourceforge.jwebunit.WebTester tester,
JIRAEnvironmentData environmentData,
Navigation navigation,
LocatorFactory locator,
Backdoor backdoor)
public void assertLastChangeHistoryRecords(String issueKey, ExpectedChangeHistoryRecord expectedChangeHistoryRecord)
AssertionsassertLastChangeHistoryRecords in interface AssertionsissueKey - The issue to checkexpectedChangeHistoryRecord - A ExpectedChangeHistoryRecord
itempublic void assertNewestChangeHistoryRecord(String issueKey, String authorName, List<ExpectedChangeHistoryItem> expectedChangeHistoryItems)
AssertionsassertNewestChangeHistoryRecord in interface AssertionsissueKey - - issue to check history entries inauthorName - - key name of the authorexpectedChangeHistoryItems - - A list of ExpectedChangeHistoryItem itemspublic CommentAssertions comments(Iterable<String> comments)
Assertionscomments in interface Assertionscomments - The comments that will be used in the assertions.public CommentAssertions comments(String... comments)
Assertionscomments in interface Assertionscomments - The comments that will be used in the assertions.public void assertLastChangeHistoryRecords(String issueKey, List expectedChangeHistoryRecords)
AssertionsassertLastChangeHistoryRecords in interface AssertionsissueKey - The issue to checkexpectedChangeHistoryRecords - A list of ExpectedChangeHistoryRecordspublic HTMLAssertions html()
Assertionshtml in interface Assertionspublic TextAssertions text()
AssertionsAssertions.getTextAssertions().text in interface Assertionspublic LinkAssertions link()
AssertionsAssertions.getLinkAssertions().link in interface Assertionspublic JiraFormAssertions forms()
AssertionsAssertions.getJiraFormAssertions().forms in interface Assertionspublic PluginAssertions plugins()
Assertionsplugins in interface Assertionspublic IssueNavigatorAssertions getIssueNavigatorAssertions()
AssertionsgetIssueNavigatorAssertions in interface Assertionspublic ViewIssueAssertions getViewIssueAssertions()
Assertionsnavigation.issue().viewIssue("RAT-1") to get to the required Issue.getViewIssueAssertions in interface AssertionsIssueNavigation.viewIssue(String)public DashboardAssertions getDashboardAssertions()
getDashboardAssertions in interface Assertionspublic JiraFormAssertions getJiraFormAssertions()
getJiraFormAssertions in interface Assertionspublic JiraMessageAssertions getJiraMessageAssertions()
getJiraMessageAssertions in interface Assertionspublic ProjectFieldsAssertions getProjectFieldsAssertions()
getProjectFieldsAssertions in interface Assertionspublic URLAssertions getURLAssertions()
getURLAssertions in interface Assertionspublic TextAssertions getTextAssertions()
getTextAssertions in interface Assertionspublic LinkAssertions getLinkAssertions()
getLinkAssertions in interface Assertionspublic LabelAssertions getLabelAssertions()
getLabelAssertions in interface Assertionspublic TableAssertions getTableAssertions()
getTableAssertions in interface Assertionspublic UserAssertions getUserAssertions()
getUserAssertions in interface Assertionspublic RequestAssertions getRequestAssertions()
getRequestAssertions in interface Assertionspublic SidebarAssertions getSidebarAssertions()
getSidebarAssertions in interface Assertionspublic void assertEquals(String failureMessage, List expected, List actual)
assertEquals in interface AssertionsfailureMessage - The message (prefix) to use to describe a failure.expected - the expected list.actual - the actual list to be tested.public void assertProfileLinkPresent(String id, String linkText)
AssertionsassertProfileLinkPresent in interface Assertionsid - The id of the profileLinklinkText - The Text of the profileLink (usually the user's full name).public void assertNodeByIdExists(String id)
AssertionsassertNodeByIdExists in interface Assertionsid - the id of the nodepublic void assertNodeByIdDoesNotExist(String id)
AssertionsassertNodeByIdDoesNotExist in interface Assertionsid - the id of the nodepublic void assertNodeByIdEquals(String id, String textToTest)
AssertionsassertNodeByIdEquals in interface Assertionsid - The id of the node to testtextToTest - The text to test forpublic void assertNodeByIdHasText(String id, String textToTest)
AssertionsassertNodeByIdHasText in interface Assertionsid - The id of the node to testtextToTest - The text to test forpublic void assertNodeByIdDoesNotHaveText(String id, String textToTest)
AssertionsassertNodeByIdDoesNotHaveText in interface Assertionsid - The id of the node to testtextToTest - The text to test forpublic void assertNodeExists(String xpath)
AssertionsassertNodeExists in interface Assertionsxpath - The xpath expression to evaluatepublic void assertNodeDoesNotExist(String xpath)
AssertionsassertNodeDoesNotExist in interface Assertionsxpath - The xpath expression to evaluatepublic void assertNodeHasText(String xpath, String textToTest)
AssertionsassertNodeHasText in interface Assertionsxpath - The xpath expression to evaluatetextToTest - The text to test forpublic void assertNodeDoesNotHaveText(String xpath, String textToTest)
AssertionsassertNodeDoesNotHaveText in interface Assertionsxpath - The xpath expression to evaluatetextToTest - The text to test forpublic void assertNodeExists(Locator locator)
AssertionsassertNodeExists in interface Assertionslocator - the locator for the nodepublic void assertNodeDoesNotExist(Locator locator)
AssertionsassertNodeDoesNotExist in interface Assertionslocator - the locator for the nodepublic void assertNodeEquals(Locator locator, String textToTest)
AssertionsassertNodeEquals in interface Assertionslocator - The locator that contains texttextToTest - The text to test forpublic void assertNodeHasText(Locator locator, String textToTest)
AssertionsassertNodeHasText in interface Assertionslocator - The locator that contains texttextToTest - The text to test forpublic void assertNodeDoesNotHaveText(Locator locator, String textToTest)
AssertionsassertNodeDoesNotHaveText in interface Assertionslocator - The locator to testtextToTest - The text to test forpublic void assertSubmitButtonPresentWithText(String buttonId, String buttonText)
AssertionsassertSubmitButtonPresentWithText in interface AssertionsbuttonId - The id of the button to locatebuttonText - The text the button should contain as its valuepublic void assertHttpStatusCode(com.atlassian.httpclient.api.HttpStatus code)
AssertionsassertHttpStatusCode in interface AssertionsCopyright © 2002-2024 Atlassian. All Rights Reserved.