Skip to content

Commit

Permalink
revert save facility type and modified form notification
Browse files Browse the repository at this point in the history
  • Loading branch information
nihal467 committed Dec 15, 2024
1 parent 6a2396a commit 6930d24
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 4 deletions.
2 changes: 1 addition & 1 deletion cypress/e2e/facility_spec/FacilityCreation.cy.ts
Original file line number Diff line number Diff line change
Expand Up @@ -118,7 +118,7 @@ describe("Facility Creation with multiple user roles", () => {
facilityPage.clickManageFacilityDropdown();
facilityPage.clickDeleteFacilityOption();
facilityPage.confirmDeleteFacility();
cy.verifyNotification("Facility deleted successfully");
cy.verifyNotification(`${facilityName} deleted successfully`);
});

it("Should display error when district admin tries to create facility in a different district", () => {
Expand Down
4 changes: 2 additions & 2 deletions cypress/pageobject/Facility/FacilityCreation.ts
Original file line number Diff line number Diff line change
Expand Up @@ -60,7 +60,7 @@ class FacilityPage {
}

clickSaveFacilityButton() {
cy.clickSubmitButton("Save Facility");
cy.verifyAndClickElement("#submit", "Save Facility");
}

verifyFacilityCreatedNotification() {
Expand All @@ -86,7 +86,7 @@ class FacilityPage {
}

clickUpdateFacilityButton() {
cy.clickSubmitButton("Update Facility");
cy.verifyAndClickElement("#submit", "Update Facility");
}

clickConfigureFacilityOption() {
Expand Down
2 changes: 1 addition & 1 deletion src/components/Facility/FacilityCreate.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -634,7 +634,7 @@ export const FacilityCreate = (props: FacilityProps) => {
</div>
<div className="mt-12 flex flex-col-reverse justify-end gap-3 sm:flex-row">
<Cancel onClick={() => goBack()} />
<Submit type="submit" onClick={handleSubmit} label={buttonText} />
<Submit type="button" onClick={handleSubmit} label={buttonText} />
</div>
</form>
</div>
Expand Down

0 comments on commit 6930d24

Please sign in to comment.