Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Test cases updates for NCCR, VIBE, OA Intake #376

Merged
merged 3 commits into from
Jan 24, 2025
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,7 @@ Feature: NCCR flow
And User confirms that the text of "Confidentiality" section is correct
When User clicks Go to the NCCR Platform hyperlink
Then User can confirm that it redirects them to Data Platform page
And User can see pagination for All Data Requests tab
And User can see Data Requests Awaiting My Review tab
And User can see Data Requests Awaiting My Review tab search text field
And User can see pagination for Data Requests Awaiting My Review tab
Expand All @@ -20,4 +21,3 @@ Feature: NCCR flow
When User clicks Show Filter icon
Then User can see Load Filter, Save Filter, Add Sort, and New Criteria buttons
And User can close filter
And User can see pagination for All Data Requests tab
2 changes: 1 addition & 1 deletion src/test/java/PLATFORM_BUSINESS/NCCR/pages/NCCRPage.java
Original file line number Diff line number Diff line change
Expand Up @@ -52,7 +52,7 @@ public class NCCRPage {
public WebElement rowsPaginationDataRequestsAwaitingMyReviewTab;

/**Rows pagination*/
@FindBy(xpath = "(//div [@class='btn-toolbar m-r pull-left'])[2]")
@FindBy(xpath = "//div[contains(text(),'Rows')]")
public WebElement rowsPaginationAllDataRequestTab;

/**Show filter button*/
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -98,8 +98,6 @@ Feature: Create OA Intake form
And User can see New Request button
And User can see Contact Support button
And User can verify Purchasing Online Tracking System (POTS) hyperlink is displayed
When User clicks Purchasing Online Tracking System (POTS) hyperlink
Then User is redirected to authentication page
And User can verify FFRDC Contract Administration System (FCAS) hyperlink is displayed
And User can verify that OA Intakes are pre-filtered for a logged in Leadership User
And User can verify that Request ID column can be sorted in descending and ascending order
Expand All @@ -111,8 +109,8 @@ Feature: Create OA Intake form
And User can verify that Status Date column can be sorted in descending and ascending order
And User logs out of OA Intake application

@selenium @Alena @Regression @OAIntake-657 @OAIntake-640 @OAIntake-700 @OAIntake-708
Scenario: Contracting Officer/Contract Specialist Queue
@selenium @Alena @Regression @OAIntake-657 @OAIntake-700
Scenario: Contracting Officer/Contract Specialist Queue Assigned menu
Given Leadership User logged in to OA Intake Portal
And User clicks on CO CS Queue tab
And User can verify page header is "Contracting Officer/Contract Specialist Queue"
Expand All @@ -123,13 +121,27 @@ Feature: Create OA Intake form
| Export as PDF | Export as Excel | Export as CSV |
And User can see OA Intakes - Assigned filter is preset with assigned requests
And User can remove filters for OA Intakes - Assigned requests
And User logs out of OA Intake application

@selenium @Alena @Regression @OAIntake-708
Scenario: Contracting Officer/Contract Specialist Queue Accepted menu
Given Leadership User logged in to OA Intake Portal
And User clicks on CO CS Queue tab
And User can verify page header is "Contracting Officer/Contract Specialist Queue"
And User can see OA Intakes - Accepted section
When User clicks on OA Intakes - Accepted menu
Then User can see the following options for OA Intakes - Accepted requests
| option1 | option2 | option3 |
| Export as PDF | Export as Excel | Export as CSV |
And User can see OA Intakes - Accepted filter is preset with accepted requests
And User can remove filters for OA Intakes - Accepted requests
And User logs out of OA Intake application

@selenium @Alena @Regression @OAIntake-640
Scenario: Contracting Officer/Contract Specialist Queue Cancelled menu
Given Leadership User logged in to OA Intake Portal
And User clicks on CO CS Queue tab
And User can verify page header is "Contracting Officer/Contract Specialist Queue"
And User can see OA Intakes - Cancelled section
When User clicks on OA Intakes - Cancelled menu
Then User can see the following options for OA Intakes - Cancelled requests
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -469,12 +469,9 @@ public void user_can_verify_page_header_as(String string) {
softAssert.assertTrue(oaIntakePage.pageHeaderRequestedFor.isDisplayed());
}

/**
* verify Requestor \(Requested For) Queue tab is displayed
*/
@Given("User can verify page header is {string}")
public void user_can_verify_page_header_is(String header) {
softAssert.assertEquals(oaIntakePage.leadershipQueuePageHeader.getText(), header);
oaIntakeStepsImplementation.verifyHeadrDisplayed(header);
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

missing javadoc statement for this method

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

seems like the existing Javadoc has been removed:

/**
* verify Requestor (Requested For) Queue tab is displayed
*/

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

javadoc exists for new method verifyHeadrDisplayed(header)

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I understand there is a Javadoc in the Steps Implementation class, however, it would be better to have a Javadoc here for consistency since all other methods have it.

}

/**
Expand All @@ -501,27 +498,6 @@ public void user_can_verify_purchasing_online_tracking_system_pots_hyperlink_is_
softAssert.assertTrue(oaIntakePage.hyperlinkPOTS.isDisplayed());
}

/**
* Click on POTS hyperlink
*/
@When("User clicks Purchasing Online Tracking System \\(POTS) hyperlink")
public void user_clicks_purchasing_online_tracking_system_pots_hyperlink() {
CommonUtils.clickOnElement(oaIntakePage.hyperlinkPOTS);
}

/**
* verify that User is redirected to NIH authentication page
*/
@Then("User is redirected to authentication page")
public void user_is_redirected_to_authentication_page() {
ArrayList<String> tabs = new ArrayList<>(webDriver.getWindowHandles());
webDriver.switchTo().window(tabs.get(1));
softAssert.assertTrue(oaIntakePage.nihLoginContent.isDisplayed());
webDriver.close();
webDriver.switchTo().window(tabs.get(0));
CommonUtils.sleep(2000);
}

/**
* verify (FCAS) hyperlink is displayed
*/
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@
import com.nci.automation.web.CommonUtils;
import com.nci.automation.web.WebDriverUtils;
import org.testng.Assert;
import static Hooks.Hooks.softAssert;
import static com.nci.automation.web.TestProperties.getOAntakeUrl;

public class OAIntakeStepsImplementation extends PageInitializer {
Expand Down Expand Up @@ -71,5 +72,20 @@ public void verifyTabDisplayed(String option) {
break;
}
}
}

/**
* verify header is displayed
*
* @param header
*/
public void verifyHeadrDisplayed(String header) {
switch (header) {
case "Leadership Queue (Pending Action)":
softAssert.assertEquals(oaIntakePage.leadershipQueuePageHeader.getText(), header);
break;
case "Contracting Officer/Contract Specialist Queue":
softAssert.assertEquals(oaIntakePage.pageHeaderContractingOfficer.getText(), header);
break;
}
}
}
Original file line number Diff line number Diff line change
@@ -1,60 +1,66 @@
Feature: VIBE Peer-to-Peer Appreciation Program
Feature: VIBE Peer-to-Peer Appreciation Program

Description: This feature file contains scenarios relating to VIBE Peer-to-Peer Appreciation Program
Description: This feature file contains scenarios relating to VIBE Peer-to-Peer Appreciation Program

@selenium @Alena @Regression @AWARDNOM-1 @AWARDNOM-10
Scenario: Submit VIBE Peer-to-Peer Appreciation Program request
Given Submitter User logged in to VIBE Peer-to-Peer Appreciation Program application via Portal
And User navigates to VIBE Peer-to-Peer Appreciation Program via Services menu
And Submitter User is on VIBE Peer-to-Peer Appreciation Program home page
And Submitter User can verify that What is your name field is already populated
And Submitter User chooses Yes for Would you like your appreciation to be anonymous question
And Submitter User picks "Aaren King" as a colleague to appreciate
And Submitter User describes their appreciation as " I want to express my appreciation"
And Submitter User can verify Optional Responses section is displayed
And Submitter User can verify Which value best reflects your appreciation section is displayed
And Submitter User can verify that Add Attachment option is displayed
When Submitter User submits VIBE Peer-to-Peer Appreciation Program request
Then Submitter User can verify they are redirected to general tickets view page
@selenium @Alena @Regression @AWARDNOM-1 @AWARDNOM-10
Scenario: Submit VIBE Peer-to-Peer Appreciation Program request
Given Submitter User logged in to VIBE Peer-to-Peer Appreciation Program application via Portal
And User navigates to VIBE Peer-to-Peer Appreciation Program via Services menu
And Submitter User is on VIBE Peer-to-Peer Appreciation Program home page
And Submitter User can verify that What is your name field is already populated
And Submitter User chooses Yes for Would you like your appreciation to be anonymous question
And Submitter User picks "Aaren King" as a colleague to appreciate
And Submitter User describes their appreciation as " I want to express my appreciation"
And Submitter User can verify Optional Responses section is displayed
And Submitter User can verify Which value best reflects your appreciation section is displayed
When Submitter User submits VIBE Peer-to-Peer Appreciation Program request
Then Submitter User can verify they are redirected to general tickets view page

@selenium @Alena @Regression @AWARDNOM-31 @AWARDNOM-22
Scenario: Verify options for VIBE Peer-to-Peer Appreciation Program request
Given Submitter User logged in to VIBE Peer-to-Peer Appreciation Program application via Portal
And User navigates to Tickets tab
And User opens the last VIBE Peer-to-Peer Appreciation Program request submitted
And User can verify that Approval status is "Requested"
And User can confirm Cancel button is displayed
And User can confirm Add Watchers button is displayed
And User can confirm Add Attachment button is displayed
When User clicks Cancel button
Then User can see Cancel confirmation modal
And User cancels the Cancel confirmation modal
When User clicks Add Watchers button
And User adds "Anna Nicholson" as a watcher
Then User can see that Watch List ticket field is populated with "Anna Nicholson" name
When User adds attachment
Then User can verify that VIBE attachment is added
@selenium @Alena @Regression @AWARDNOM-31 @AWARDNOM-22
Scenario: Verify options for VIBE Peer-to-Peer Appreciation Program request
Given Submitter User logged in to VIBE Peer-to-Peer Appreciation Program application via Portal
And User navigates to Tickets tab
And User opens the last VIBE Peer-to-Peer Appreciation Program request submitted
And User can verify that Approval status is "Requested"
And User can confirm Cancel button is displayed
And User can confirm Add Watchers button is displayed
And User can confirm Add Attachment button is displayed
When User clicks Cancel button
Then User can see Cancel confirmation modal
And User cancels the Cancel confirmation modal
When User clicks Add Watchers button
And User adds "Anna Nicholson" as a watcher
Then User can see that Watch List ticket field is populated with "Anna Nicholson" name
When User adds attachment
Then User can verify that VIBE attachment is added

@selenium @Alena @Regression @AWARDNOM-10 @AWARDNOM-78 @AWARDNOM-82
Scenario: Verify Optional Responses and Which value best reflects your appreciation options
Given Submitter User logged in to VIBE Peer-to-Peer Appreciation Program application via Portal
And User navigates to VIBE Peer-to-Peer Appreciation Program via Services menu
And Submitter User is on VIBE Peer-to-Peer Appreciation Program home page
And Submitter User can verify Optional Responses section is displayed
And User can verify Optional Responses option "Going Above and Beyond—They go the extra mile and provide excellent service." is displayed
And User can verify Optional Responses option "Building Our Community—They foster inclusivity and build relationships." is displayed
And User can verify Optional Responses option "Working Behind the Scenes—They perform important tasks without being in the spotlight." is displayed
And User can verify Optional Responses option "Making It Happen—They achieve results despite challenges." is displayed
And User can verify Optional Responses option "Finding Creative Solutions—They use creative problem-solving and embrace a growth mindset." is displayed
And User can verify Optional Responses option "Brightening the Day—Their positive attitude makes work more enjoyable." is displayed
And User can verify Optional Responses option "Leading the Charge—They take initiative on challenging tasks." is displayed
And User can verify Optional Responses option "Collaborating on a Project—They are key partners on projects." is displayed
And User can verify Optional Responses option "In My Own Words - A text box will appear below when checked." is displayed
And User can see Which value best reflects your appreciation option "Breaking Down Barriers—They actively work to dismantle all forms of discrimination."
And User can see Which value best reflects your appreciation option "Using Evidence—They base decisions on data and feedback to promote equity."
And User can see Which value best reflects your appreciation option "Empowering Others—They help foster a sense of belonging and inclusivity."
And User can see Which value best reflects your appreciation option "Being Trustworthy and Accountable—They promote shared responsibility and accountability in making NCI equitable and inclusive."
And User can see Which value best reflects your appreciation option "Fostering Belonging and Respect—They cultivate a respectful environment where everyone feels valued."
And User can see Which value best reflects your appreciation option "Promoting Transparency—They ensure that diversity, equity, and inclusion processes are clear and accessible."
And User can see Which value best reflects your appreciation option "Being an Ally—They advocate for marginalized or excluded colleagues."
And User can see Which value best reflects your appreciation option "In My Own Words - A text box will appear below when checked."
@selenium @Alena @Regression @AWARDNOM-10 @AWARDNOM-78 @AWARDNOM-82
Scenario: Verify Optional Responses and Which value best reflects your appreciation options
Given Submitter User logged in to VIBE Peer-to-Peer Appreciation Program application via Portal
And User navigates to VIBE Peer-to-Peer Appreciation Program via Services menu
And Submitter User is on VIBE Peer-to-Peer Appreciation Program home page
And Submitter User can verify Optional Responses section is displayed
And User can verify Optional Responses option "Going Above and Beyond—They go the extra mile and provide excellent service." is displayed
And User can verify Optional Responses option "Building Our Community—They foster inclusivity and build relationships." is displayed
And User can verify Optional Responses option "Working Behind the Scenes—They perform important tasks without being in the spotlight." is displayed
And User can verify Optional Responses option "Making It Happen—They achieve results despite challenges." is displayed
And User can verify Optional Responses option "Finding Creative Solutions—They use creative problem-solving and embrace a growth mindset." is displayed
And User can verify Optional Responses option "Brightening the Day—Their positive attitude makes work more enjoyable." is displayed
And User can verify Optional Responses option "Leading the Charge—They take initiative on challenging tasks." is displayed
And User can verify Optional Responses option "Collaborating on a Project—They are key partners on projects." is displayed
And User can verify Optional Responses option "In My Own Words - A text box will appear below when checked." is displayed

@selenium @Alena @Regression @AWARDNOM-78 @AWARDNOM-82
Scenario: Verify Optional Responses
Given Submitter User logged in to VIBE Peer-to-Peer Appreciation Program application via Portal
And User navigates to VIBE Peer-to-Peer Appreciation Program via Services menu
And Submitter User is on VIBE Peer-to-Peer Appreciation Program home page
And Submitter User can verify Optional Responses section is displayed
And User can see Which value best reflects your appreciation option "Breaking Down Barriers—They actively work to dismantle all forms of discrimination."
And User can see Which value best reflects your appreciation option "Using Evidence—They base decisions on data and feedback to promote equity."
And User can see Which value best reflects your appreciation option "Empowering Others—They help foster a sense of belonging and inclusivity."
And User can see Which value best reflects your appreciation option "Being Trustworthy and Accountable—They promote shared responsibility and accountability in making NCI equitable and inclusive."
And User can see Which value best reflects your appreciation option "Fostering Belonging and Respect—They cultivate a respectful environment where everyone feels valued."
And User can see Which value best reflects your appreciation option "Promoting Transparency—They ensure that diversity, equity, and inclusion processes are clear and accessible."
And User can see Which value best reflects your appreciation option "Being an Ally—They advocate for marginalized or excluded colleagues."
And User can see Which value best reflects your appreciation option "In My Own Words - A text box will appear below when checked."
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,7 @@ public class AwardNominationPage {
public WebElement chosenPerson;

/** text field Share Appreciation*/
@FindBy(xpath = "//textarea[@id='sp_formfield_reason_for_your_appreciations']")
@FindBy(xpath = "//textarea[@id='sp_formfield_share_your_appreciation']")
public WebElement textFieldShareAppreciation;

/** section Header Optional Responses*/
Expand All @@ -67,6 +67,10 @@ public class AwardNominationPage {
@FindBy(xpath = "//span[.=' Tickets ']")
public WebElement sectionTickets;

/** confirmation We have received your request */
@FindBy(xpath = "//h2[.='We have received your request.']")
public WebElement confWeHaveReceivedYourRequest;

/** Last submitted VIBE Ticket */
@FindBy(xpath = "(//h4[.='VIBE Peer-to-Peer Appreciation Program'])[1]")
public WebElement lastSubmittedVIBETicket;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -54,19 +54,14 @@ public void submitter_user_can_verify_which_value_best_reflects_your_appreciatio
awardNominationStepsImplementation.verifySectionAppreciationValueDisplayed();
}

@Given("Submitter User can verify that Add Attachment option is displayed")
public void submitter_user_can_verify_that_add_attachment_option_is_displayed() {
awardNominationStepsImplementation.verifySectionAddAttachmentDisplayed();
}

@When("Submitter User submits VIBE Peer-to-Peer Appreciation Program request")
public void submitter_user_submits_vibe_peer_to_peer_appreciation_program_request() {
awardNominationStepsImplementation.clickSubmitButton();
}

@Then("Submitter User can verify they are redirected to general tickets view page")
public void submitter_user_can_verify_they_are_redirected_to_general_tickets_view_page() {
awardNominationStepsImplementation.verifySectionTicketsDisplayed();
awardNominationStepsImplementation.verifyWeHaveReceivedRequest();
}

/**
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -107,10 +107,10 @@ public void clickSubmitButton() {
}

/**
* verify Tickets section displayed
* verify we have received request displayed
*/
public void verifySectionTicketsDisplayed() {
softAssert.assertTrue(awardNominationPage.sectionTickets.isDisplayed());
public void verifyWeHaveReceivedRequest() {
softAssert.assertTrue(awardNominationPage.confWeHaveReceivedYourRequest.isDisplayed());
}

/**
Expand Down