Skip to content

Commit

Permalink
HPCC-31857 : Description Functionality Testing - Modified Loggers
Browse files Browse the repository at this point in the history
  • Loading branch information
Nisha-Bagdwal committed Jun 28, 2024
1 parent bdbe5cf commit 3025b75
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 11 deletions.
8 changes: 4 additions & 4 deletions esp/src/test-ui/tests/framework/pages/BaseTableTest.java
Original file line number Diff line number Diff line change
Expand Up @@ -68,15 +68,15 @@ protected void testPage() {
try {
Common.logDebug("Tests started for: " + getPageName() + " page.");

//testForAllText();
testForAllText();

jsonObjects = getAllObjectsFromJson();
if (jsonObjects != null) {

int numOfItemsJSON = jsonObjects.size();
clickDropdown(numOfItemsJSON);

//testContentAndSortingOrder();
testContentAndSortingOrder();
}

testLinksInTable();
Expand All @@ -90,8 +90,8 @@ protected void testPage() {

private void testDetailsPage(String name, int i) {

//testForAllTextInDetailsPage(name);
//testDetailsContentPage(name);
testForAllTextInDetailsPage(name);
testDetailsContentPage(name);

// if(i == 0){
// testDetailSpecificFunctionality(name);
Expand Down
10 changes: 3 additions & 7 deletions esp/src/test-ui/tests/framework/pages/ECLWorkUnitsTest.java
Original file line number Diff line number Diff line change
Expand Up @@ -142,12 +142,10 @@ private void testIfTheDescriptionUpdated(String wuName, String newDescription) {

String updatedDescription = element.getAttribute(getAttributeValueForDetailsPage()).trim();

Common.logDetail("Updated Description After refresh: "+ updatedDescription);

if (newDescription.equals(updatedDescription)) {
Common.logDetail("Success: "+ getPageName() +" Details page. Description Update Successfully for WUID: " + wuName);
Common.logDetail("Success: "+ getPageName() +" Details page. Description Updated Successfully on click of save button: Description After refresh showing on UI: "+ updatedDescription+", Updated description was: "+newDescription+" for WUID: " + wuName);
}else{
Common.logError("Failure: "+ getPageName() +" Details page. Description Did Not Update for WUID on click of save button: " + wuName);
Common.logError("Failure: "+ getPageName() +" Details page. Description Did Not Update on click of save button : Description After refresh showing on UI: "+ updatedDescription+", Updated description should be: "+newDescription+" for WUID: " + wuName);
}
}

Expand All @@ -159,8 +157,6 @@ private String updateDescriptionAndSave(String newDescription) {

String oldDescription = element.getAttribute(getAttributeValueForDetailsPage());

Common.logDetail("Old Description: "+ oldDescription);

element.sendKeys(Keys.CONTROL + "a"); // Select all text
element.sendKeys(Keys.DELETE); // Delete all selected text

Expand All @@ -173,7 +169,7 @@ private String updateDescriptionAndSave(String newDescription) {
Common.sleepWithTime(4); // need to modify this to wait dynamically

element = Common.waitForElement(By.id("description"));
Common.logDetail("Updated Description After Save: " + element.getAttribute(getAttributeValueForDetailsPage()));
Common.logDetail("Old Description: "+ oldDescription +", Updated Description After Save: " + element.getAttribute(getAttributeValueForDetailsPage()));

return oldDescription;
}
Expand Down

0 comments on commit 3025b75

Please sign in to comment.