Skip to content

Unit test coverage for RSVP Template.#1251

Merged
mauteri merged 4 commits intodevelopfrom
version-0.33.0-beta.1
Dec 6, 2025
Merged

Unit test coverage for RSVP Template.#1251
mauteri merged 4 commits intodevelopfrom
version-0.33.0-beta.1

Conversation

@mauteri
Copy link
Copy Markdown
Contributor

@mauteri mauteri commented Dec 6, 2025

Description of the Change

Closes #

How to test the Change

Changelog Entry

Added - New feature
Changed - Existing functionality
Deprecated - Soon-to-be removed feature
Removed - Feature
Fixed - Bug fix
Security - Vulnerability

Credits

Props @username, @username2, ...

Checklist:

  • I agree to follow this project's Code of Conduct.
  • I have updated the documentation accordingly.
  • I have added tests to cover my change.
  • All new and existing tests pass.

@what-the-diff
Copy link
Copy Markdown

what-the-diff bot commented Dec 6, 2025

PR Summary

  • Addition of New Test Methods to the RSVP_Template Class:
    These tests have been added to class-test-rsvp-template.php to ensure the functionality of the RSVP_Template class.
    • Test for ensure_block_styles_loaded

      This test validates the loading of block styles in varying conditions:

      • When there is no data-blocks attribute.
      • When data-blocks is empty.
      • When data-blocks is valid.
    • Test for generate_rsvp_template_block

      This test verifies the generation of the RSVP template block under different conditions:

      • For non-event posts.
      • For unpublished events.
      • For published events, ensuring interactive elements display correctly.
    • Test for get_block_content

      This test examines multiple scenarios for retrieving block content:

      • Regular retrieval of block content.
      • Retrieving block content with limit conditions, whether exceeded or not.
      • Handling anonymity in RSVPs.
    • Test for anonymize_rsvp_blocks

      This test ensures that identifiable information (like avatar and comment author name) in RSVPs is properly concealed when required.

@mauteri mauteri marked this pull request as ready for review December 6, 2025 01:42
@mauteri mauteri merged commit d7421b2 into develop Dec 6, 2025
11 checks passed
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.

1 participant