Skip to content

Commit

Permalink
Resolve All firefox failures (openmrs#431)
Browse files Browse the repository at this point in the history
* Resolve All firefox failures

* try again with expected conditions

* Sanity check

* Revert sanity check

Co-authored-by: dkayiwa <[email protected]>
  • Loading branch information
sherrif10 and dkayiwa authored Jul 20, 2022
1 parent 725b180 commit 9edd690
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 5 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ public class VisitNotePage extends Page {
private static final By CODE = By.className("code");
private static final By UI_ID_1 = By.id("ui-id-1");
private static final By UI_MENU_ITEM = By.className("ui-menu-item");
private static final By PRIMARY_DIAGNOSIS_ELEMENT = By.cssSelector(".diagnosis.primary .matched-name");
private static final By PRIMARY_DIAGNOSIS_ELEMENT = By.xpath("//ul[1]/li/span/div/strong");
private static final By SECONDARY_DIAGNOSIS_ELEMENT = By.xpath("//ul[2]/li/span/div/strong");
private static final By SAVE_VISIT_NOTE = By.cssSelector(".submitButton.confirm");
private static final By NOTE = By.id("w10");
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -9,9 +9,9 @@
*/
package org.openmrs.contrib.qaframework.automation;

import static org.junit.Assert.assertEquals;
import static org.junit.Assert.assertNotNull;
import static org.junit.Assert.assertTrue;
import static org.junit.Assert.assertEquals;

import io.cucumber.java.After;
import io.cucumber.java.Before;
Expand Down Expand Up @@ -119,7 +119,7 @@ public void enterDiagnosis() {

@Then("the system saves the diagnosis into the visit note table")
public void systemAddsDiagnosis() {
assertEquals("Pneumonia", visitNotePage.primaryDiagnosis());
assertEquals(DIAGNOSIS_SECONDARY_UPDATED, visitNotePage.primaryDiagnosis());
assertEquals("Bleeding", visitNotePage.secondaryDiagnosis());
}

Expand All @@ -131,7 +131,8 @@ public void deleteVisitNote() {
}

@Then("the system deletes the visit note")
public void systemdeletesVisitNotePage() {
public void systemDeletesVisitNotePage() {
assertTrue(textExists("deleted"));
}

}
Original file line number Diff line number Diff line change
Expand Up @@ -173,6 +173,5 @@ public void editPatientVitals() {
@And("a user clicks on the save changes button")
public void saveUpdatedVitals() {
editVitalsPage.saveChanges();
editVitalsPage.waitForPage();
}
}

0 comments on commit 9edd690

Please sign in to comment.