Skip to content

Commit

Permalink
Merge pull request #347 from CBIIT/Alena
Browse files Browse the repository at this point in the history
Award Nomination App. Cancel, Add watchers, Add Attachments
  • Loading branch information
Mariachaudhry authored Dec 17, 2024
2 parents 831ab36 + 33b3b4b commit f5c46a7
Show file tree
Hide file tree
Showing 15 changed files with 337 additions and 216 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ Feature: CADSR feature files
When User Logins to the caDSR application
Then Go to Native view of the application
Then Go to CADSR Requests
Then Start a new request on nativ view
Then Start a new request on native view
Then User should see Save, Add Attachments and Submit button


Expand All @@ -25,7 +25,7 @@ Feature: CADSR feature files
When User Logins to the caDSR application
Then Go to Native view of the application
Then Go to CADSR Requests
Then Start a new request on nativ view
Then Start a new request on native view
Then User should see available different choices of status

@SNOWCADSR-200
Expand Down
46 changes: 13 additions & 33 deletions src/test/java/PLATFORM_BUSINESS/CADSR/steps/NativeViewSteps.java
Original file line number Diff line number Diff line change
Expand Up @@ -27,9 +27,6 @@ public void openATOApp() {

@When("User Logins to the CADSR application")
public void login() throws Exception {
//loginStepsImpl.enterUsername(ConfUtils.getProperty("sgugulothuUsername"));
//String decyptedPass = EncryptionUtils.decrypt(ConfUtils.getProperty("sgugulothuPassword"));
//loginStepsImpl.enterPassword(decyptedPass);
loginStepsImpl.clickOnSignInButton();
}

Expand All @@ -38,18 +35,14 @@ public void getNativeView() {
nativeViewPage.clickOnNativeView();
}




@Then("Go to CADSR Requests")
public void clickonCADSRRequest() throws InterruptedException {
public void clickOnCADSRRequest() throws InterruptedException {
nativeViewPage.clickOnCADSRRequest();
}

@Then("User should see default columns for incident grid")
public void viewDefaultColumns() throws InterruptedException {
nativeViewPage.viewDefaultColumns();

}

@Then("Go to All Business Case")
Expand Down Expand Up @@ -85,7 +78,7 @@ public void approveRequest() throws InterruptedException {
}

@Then("State is Updated to {string}")
public void verifystate(String expectedState) throws Exception {
public void verifyState(String expectedState) throws Exception {
Thread.sleep(2000);
String actualState = nativeViewPage.getState();
CucumberLogUtils.logScreenshot();
Expand All @@ -102,73 +95,63 @@ public void openLatestBusinessCase() {

@Then("Update details on Business form and submit")
public void FillBusinessForm() throws InterruptedException {
nativeViewPage.enterTextInBusinessNeedBox("TestingAutomtaionTesting");
nativeViewPage.enterTextInBusinessNeedBox("TestingAutomationTesting");
}

@Then("Open Request Approval form and approve")
public void approve() throws InterruptedException {
nativeViewPage.approveRequestForm();
}

@Then("Click on Elevate Permision")
@Then("Click on Elevate Permission")
public void elevatePermission() throws InterruptedException {
nativeViewPage.elevateButton();
}

@Then("User should see Save, Add Attachments and Submit button")
public void user_should_see_Save_Add_Attachments_and_Submit_button() {
nativeViewPage.switchToFrame();

Assert.assertTrue("Save button is not present on the screen",
nativeViewPage.isElementPresent(nativeViewPage.saveButton));
Assert.assertTrue("Add Attachement button is not present on the screen",
Assert.assertTrue("Add Attachment button is not present on the screen",
nativeViewPage.isElementPresent(nativeViewPage.addAttachemdnBottom));
Assert.assertTrue("Submit button is not present on the screen",
nativeViewPage.isElementPresent(nativeViewPage.submitButtonOnNewRequestForm));


}

@Then("Start a new request on nativ view")
public void start_new_Requst() {
@Then("Start a new request on native view")
public void start_new_Request() {
nativeViewPage.startANewRequest();
}



@Then("User should see available different choices of status")
public void validateStatusCHoices() throws Exception {
public void validateStatusChoices() throws Exception {
nativeViewPage.allSelectOptions();

}

@Then("take the final page screenshot and add it to the report")
public void logScreenshot() {

}

@Then("Set Assigned to and save")
public void set_assigned_to() {
nativeViewPage.selectAssignedTo("Janice Knable");
nativeViewPage.justSaveTicket();

}

@Then("Validate assigned to value in child ticket")
public void validate_assigned_to() throws InterruptedException {

String value = nativeViewPage.getAssignedToValue();
Assert.assertTrue("Assigned to value in child ticket is not correct", "Janice Knable".equalsIgnoreCase(value));
}

@Then("User should see Status field")
public void user_should_see_Status_field() {
nativeViewPage.validateTheLabelAsStatus();

}

@Then("Validate parent ticket reference")
public void validatePerenetTicketReference() {

public void validateParentTicketReference() {
nativeViewPage.validateParentTicketReference();
}

Expand All @@ -178,8 +161,7 @@ public void validateTextOnLandingPage() {
}

@Then("validate text on request form page")
public void validateTextonRequestFormPage() {

public void validateTextOnRequestFormPage() {
nativeViewPage.validateTextOnRequestFormPage();
}

Expand All @@ -191,12 +173,10 @@ public void enterOneMoreEmailId() {
@Then("validate page footer")
public void validatePageFooter() {
nativeViewPage.checkIfPageFooterISasExpected();

}

@Then("validate that the list of organiation is as expected")
@Then("validate that the list of organization is as expected")
public void validateTheListOfOrganization() throws Exception {
nativeViewPage.validateTheListOfOrganization();

}
}
Loading

0 comments on commit f5c46a7

Please sign in to comment.