Skip to content

Commit

Permalink
added the functionality to upload the cover photo while doing the fac…
Browse files Browse the repository at this point in the history
…ility creation.
  • Loading branch information
arnit-coder committed Feb 29, 2024
1 parent c24d866 commit 8a25103
Show file tree
Hide file tree
Showing 4 changed files with 325 additions and 55 deletions.
13 changes: 13 additions & 0 deletions cypress/pageobject/Facility/FacilityCreation.ts
Original file line number Diff line number Diff line change
Expand Up @@ -60,6 +60,19 @@ class FacilityPage {
fillPhoneNumber(phoneNumber: string) {
cy.get("#phone_number").type(phoneNumber);
}
clickCoverImage() {
cy.get("#facility-coverimage").click({ force: true });
}

verifyUploadButtonVisible() {
cy.get("#upload-cover-image").should("be.visible");
}

uploadCoverImage(fileName) {
cy.get("#upload-cover-image")
.selectFile(`cypress/fixtures/${fileName}`, { force: true })
.wait(100); // Adjust the wait time as needed
}

submitForm() {
cy.get("button#submit").click();
Expand Down
Loading

0 comments on commit 8a25103

Please sign in to comment.