Skip to content

Provide Mock classes #194

Description

@2e0byo

Consumers want to test passing around valid tracks/artists/etc. Our current design makes this sufficiently hard that the best way is to use Mock(). It would be good to make it possible to spin up a valid Artist/Album/Track etc without needing e.g. a valid session.

This might be done in several ways:

  • provide a MockSession (initially just Mock(spec=Session)) and a way of creation objects against it (probably via .new).
  • decouple our datastructures further from how we get them

I've not thought deeply about the challenges of doing this. Some of the workarounds can be seen in the tests for mopidy-tidal.

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

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions