Skip to content

fix: fixes cypress landing page test error for every new PR in 2025#506

Merged
ashmit-coder merged 2 commits intoasyncapi:masterfrom
DevanjoyDas:fix/cypress-test-error
Jan 17, 2025
Merged

fix: fixes cypress landing page test error for every new PR in 2025#506
ashmit-coder merged 2 commits intoasyncapi:masterfrom
DevanjoyDas:fix/cypress-test-error

Conversation

@DevanjoyDas
Copy link
Contributor

Description

This pull request addresses a failing Cypress end-to-end test on the landing page. The test, which verifies the heading contains the current year, was causing failures for new PRs in 2025 due to the dynamic year calculation.

To avoid prematurely changing the header to "AsyncAPI Conf On Tour 2025", the test has been updated to handle both the current year and the previous year dynamically to allow flexibility until the official event dates for 2025 are confirmed :

const Year = new Date().getFullYear();
   cy.getTestData("landing-heading").contains(new RegExp(`AsyncAPI Conf On Tour (${Year}|${Year-1})`));

Screenshot of the passing test case.
image

Important
Temporarily adjusted the test to allow flexibility until the official event dates for 2025 are confirmed.

Fixes #505

@netlify
Copy link

netlify bot commented Jan 2, 2025

Deploy Preview for peaceful-ramanujan-288045 ready!

Built without sensitive environment variables

Name Link
🔨 Latest commit b1c2b09
🔍 Latest deploy log https://app.netlify.com/sites/peaceful-ramanujan-288045/deploys/6789f8e520bfe40008bcff3f
😎 Deploy Preview https://deploy-preview-506--peaceful-ramanujan-288045.netlify.app
📱 Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.

To edit notification comments on pull requests, go to your Netlify site configuration.

Copy link
Contributor

@ashmit-coder ashmit-coder left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM!

@ashmit-coder ashmit-coder merged commit e7aa268 into asyncapi:master Jan 17, 2025
13 checks passed
vincenthirtz pushed a commit to vincenthirtz/conference-website that referenced this pull request Dec 19, 2025
…api#506)

Co-authored-by: Ashmit Jagtap <ashmitjagtap2209@gmail.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[BUG] Cypress Landing Page Test ("Contains correct heading") Fails for New PRs Due to 2025 Year Change

2 participants

Comments