Skip to content

Feature: Update config to work with new mock models #821

Description

@Mclilzee

Checks

  • I have thoroughly read and understand The Odin Project Contributing Guide
  • The title of this issue follows the command name: brief description of request format, e.g. /help: add optional @user parameter

Do you want to be assigned to this issue?

  • I would like to be assigned this issue to work on it

Description of the Feature Request

While working on #793 and updating the new Mock Models, I realized most of the mock models can be filled directly from our config.js file.

The problem is the config.js file is formatted in a way to be easier to work with for some tests. If we format it properly for example each role or channel in the array being
{ id, name } then we can create a default mocks that will auto-inject all of these values directly for our tests without having to manually fill them every time.

If necessary we can add more values to the config so that we can simulate our whole discord server, the only thing that would be missing is members, which we will still have to rely on fake members that we create manually.

Acceptance Criteria

  • Reformat config file and refactor all places where its being used.
  • Create default mocks for TextChannel, Guild, Roles etc

Additional information

No response

Metadata

Metadata

Assignees

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