Skip to content

Add e2e exceptions for black friday#2587

Merged
Crabcyborg merged 1 commit into
masterfrom
add_e2e_exceptions_for_black_friday
Nov 18, 2025
Merged

Add e2e exceptions for black friday#2587
Crabcyborg merged 1 commit into
masterfrom
add_e2e_exceptions_for_black_friday

Conversation

@Crabcyborg
Copy link
Copy Markdown
Contributor

No description provided.

@Crabcyborg Crabcyborg marked this pull request as ready for review November 18, 2025 15:46
@coderabbitai
Copy link
Copy Markdown
Contributor

coderabbitai Bot commented Nov 18, 2025

Walkthrough

These changes extend Cypress E2E tests to accept additional banner and CTA text variations, specifically adding "Black Friday Deals" as a valid option. One test refactors validation logic from multiple OR conditions to array-based substring matching.

Changes

Cohort / File(s) Summary
Test expectation expansion
tests/cypress/e2e/Entries/EntriesPageDataValidations.cy.js
Extended frm-tip-cta text expectation list to include "Black Friday Deals" alongside existing "Upgrade to Pro." and "Get 60% Off Pro!"
Test refactoring and data update
tests/cypress/e2e/Forms/formPageDataValidation.cy.js
Refactored banner text validation from multi-clause OR conditions to consolidated substrings array with Array.prototype.some check; added "Black Friday Deals" to allowed texts; replaced regex matching with substring matching

Estimated code review effort

🎯 2 (Simple) | ⏱️ ~8 minutes

  • Both changes are isolated to test files with straightforward updates
  • The refactoring in formPageDataValidation.cy.js is a standard pattern conversion that maintains existing control flow
  • Verify that the new substring matching approach (replacing regex) covers all intended banner text variations

Possibly related PRs

Pre-merge checks and finishing touches

❌ Failed checks (1 inconclusive)
Check name Status Explanation Resolution
Description check ❓ Inconclusive No description was provided by the author, making it impossible to evaluate relevance to the changeset. Add a pull request description explaining the purpose of the Black Friday exceptions and why they are needed in the e2e tests.
✅ Passed checks (2 passed)
Check name Status Explanation
Title check ✅ Passed The title 'Add e2e exceptions for black friday' directly and clearly describes the main change: adding exceptions to end-to-end tests for Black Friday scenarios.
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.
✨ Finishing touches
  • 📝 Generate docstrings
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Post copyable unit tests in a comment
  • Commit unit tests in branch add_e2e_exceptions_for_black_friday

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands and usage tips.

Copy link
Copy Markdown
Contributor

@coderabbitai coderabbitai Bot left a comment

Choose a reason for hiding this comment

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

Actionable comments posted: 0

🧹 Nitpick comments (1)
tests/cypress/e2e/Forms/formPageDataValidation.cy.js (1)

21-27: Excellent refactor for maintainability.

Extracting the promotional text options into a dedicated array significantly improves readability and makes it easier to add or remove options in the future. The addition of 'Black Friday Deals' fits naturally into this cleaner structure.

📜 Review details

Configuration used: CodeRabbit UI

Review profile: CHILL

Plan: Pro

📥 Commits

Reviewing files that changed from the base of the PR and between 5be611a and 52d7a2e.

📒 Files selected for processing (2)
  • tests/cypress/e2e/Entries/EntriesPageDataValidations.cy.js (1 hunks)
  • tests/cypress/e2e/Forms/formPageDataValidation.cy.js (1 hunks)
⏰ Context from checks skipped due to timeout of 90000ms. You can increase the timeout in your CodeRabbit configuration to a maximum of 15 minutes (900000ms). (5)
  • GitHub Check: Cypress
  • GitHub Check: PHP 7.4 tests in WP trunk
  • GitHub Check: PHP 8 tests in WP trunk
  • GitHub Check: PHP 7.4 tests in WP trunk
  • GitHub Check: PHP 8 tests in WP trunk
🔇 Additional comments (2)
tests/cypress/e2e/Entries/EntriesPageDataValidations.cy.js (1)

55-56: LGTM! Consistent addition of promotional text option.

The addition of 'Black Friday Deals' aligns with the PR objective and maintains consistency with the similar change in formPageDataValidation.cy.js.

tests/cypress/e2e/Forms/formPageDataValidation.cy.js (1)

29-29: Cleaner validation logic.

The refactor from multiple OR conditions to Array.some() with substring matching is more maintainable and easier to extend. This approach correctly validates that at least one expected promotional message appears in the banner text.

@Crabcyborg Crabcyborg merged commit 7a0e4b4 into master Nov 18, 2025
32 of 35 checks passed
@Crabcyborg Crabcyborg deleted the add_e2e_exceptions_for_black_friday branch November 18, 2025 16:27
stephywells pushed a commit that referenced this pull request Apr 4, 2026
…_friday

Add e2e exceptions for black friday
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant