Skip to content

[12.x] Enhance Broadcast Events Test Coverage #55458

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Conversation

roshandelpoor
Copy link
Contributor

@roshandelpoor roshandelpoor commented Apr 17, 2025

This PR adds test coverage for custom broadcasting configurations, focusing on multiple channels, custom connections, event names, and payload handling.

Added Test Cases

  • testBroadcastWithMultipleChannels
    • Verifies broadcasting to multiple channels simultaneously
    • Tests handling of ['channel-1', 'channel-2'] configuration
  • testBroadcastWithCustomConnectionName
    • Tests broadcasting with custom connection name
    • Ensures custom connection property is properly handled
  • testBroadcastWithCustomEventName
    • Validates custom event name broadcasting via broadcastAs()
    • Ensures event name customization works as expected
  • testBroadcastWithCustomPayload
    • Tests custom payload broadcasting via broadcastWith()
    • Verifies custom data handling in broadcast payloads

Why

These test cases ensure that the broadcasting system correctly handles:

  • Multiple channel broadcasting scenarios
  • Custom connection configurations
  • Event name customization
  • Custom payload data

@taylorotwell taylorotwell merged commit 98f9785 into laravel:12.x Apr 18, 2025
60 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.

2 participants