Skip to content

Commit

Permalink
Merge pull request #1086 from necyberteam/md-dev
Browse files Browse the repository at this point in the history
Md dev
  • Loading branch information
a-pasquale authored Feb 2, 2024
2 parents 3a398a1 + cb43c07 commit 74628cf
Show file tree
Hide file tree
Showing 3 changed files with 34 additions and 16 deletions.
8 changes: 4 additions & 4 deletions composer.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

16 changes: 8 additions & 8 deletions tests/cypress/cypress/e2e/accessmatch/ccep/ccep.cy.js
Original file line number Diff line number Diff line change
Expand Up @@ -9,36 +9,36 @@ describe("Unauthenticated user tests the CCEP Page", () => {
it("Should test CCEP page for unauthenticated user", () => {
cy.visit("/ccep");

//Page Intro paragraph
// Page Intro paragraph
cy.get("#about").contains(
"CCEP (CSSN Community Engagement Program) gives travel rewards to ANYONE"
);
cy.get("#about > :nth-child(2)").contains(
"Submissions are reviewed once a month"
);

//Tier 1 Accordion Section
cy.get("#tier1 > h2").contains("Tier 1: $1,000");
cy.get("#tier1 > :nth-child(2) > .bg-light-teal")
// Accordion Section
cy.get("#about > h2").contains("$3,000");
cy.get("section:nth-child(2) > :nth-child(2) > .bg-light-teal")
.contains("Intro to ACCESS lecture")
.click();
cy.get('[open=""] > .bg-white').contains(
"Prepare an Intro to ACCESS lecture, tutorial, or slide deck for Basic, Intermediate, or Advanced User."
"Prepare an Intro to ACCESS lecture"
);

//Apply To CCEP Button
// Apply To CCEP Button
cy.get(".btn")
.contains("Apply to CCEP")
.should("have.attr", "href")
.and("contain", "https://forms.gle/u4d4kCtsYNQgzxjq5");

//Important Fine Print Section
// Important Fine Print Section
cy.visit("/ccep");
cy.get("#fine-print").contains(
"CCEP (CSSN Community Engagement Program) gives travel rewards to ANYONE for community engagement, feedback forums,"
);

//Testing See All Details click function and Intro text of /ccep/ccep-details
// Testing See All Details click function and Intro text of /ccep/ccep-details
cy.get(".container > :nth-child(3) > a")
.contains("See all the details")
.click();
Expand Down
26 changes: 22 additions & 4 deletions tests/cypress/cypress/e2e/accessmatch/tags/tag-individual.cy.js
Original file line number Diff line number Diff line change
Expand Up @@ -8,16 +8,15 @@ describe("Verify the the community-outreach tag page", () => {

checkTitleAndBreadcrumbs();
checkSectionAffinityGroups();
checkSectionAnnouncementsEvents('.view-id-tagged_news_block', '/announcements/');
checkSectionAnnouncementsEvents('.view-id-recurring_events_event_instances', '/events/');
checkSectionAnnouncements('.view-id-tagged_news_block', '/announcements/');
checkSectionEvents('.view-id-recurring_events_event_instances', '/events/');
checkSectionInterestedSkilled('.view-people-with-expertise-tags', 'expertise');
checkSectionInterestedSkilled('.view-people-with-interest-tags', 'interest');
checkSectionCILinks();

/////////////////////////////////////////////////////////////////////////

function checkSectionAnnouncementsEvents(blockclass, href_type) {

function checkSectionAnnouncements(blockclass, href_type) {
cy.get(blockclass)
.find('tbody')
.find('tr')
Expand All @@ -31,6 +30,25 @@ describe("Verify the the community-outreach tag page", () => {

/////////////////////////////////////////////////////////////////////////

function checkSectionEvents(blockclass, href_type) {

cy.get('body').then(($body) => {
if (!$body.text().includes('No events or trainings are currently scheduled.')) {
cy.get(blockclass)
.find('tbody')
.find('tr')
.each((row) => {
cy.wrap(row).find('a').should('have.attr', 'href')
.and('contain', href_type);
cy.wrap(row).find('.view-field-published-date-table-column')
.should('not.be.empty');
});
}
})
}

/////////////////////////////////////////////////////////////////////////

function checkSectionInterestedSkilled(blockclass, skillOrInterest) {

cy.get(blockclass)
Expand Down

0 comments on commit 74628cf

Please sign in to comment.