Skip to content

test reconnection logic in WebSocketProvider #14

Open
@heckj

Description

I just cobbled up a bunch of WebSocket related reconnect-on-error logic, including a backoff mechanism. However, there's not really anything easily set up to "fake" a websocket to allow me to test this outside of some sort of broader integration/live testing scenario.

Go through and see if the logic can be tweaked/updated to allow injecting a fake thing that creates a WebSocketTask equivalent (or something that smells and acts like one), and use it to add tests to verify that the various permutations all work as expected.

  • failed on receive()
  • failed on send()
  • corrupted messages
  • disconnect() terminating things correctly

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    testingtesting of existing code or functionality

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions