Skip to content

feat: mock.toBeCalledWithArgs(...) #166

@crookse

Description

@crookse

Summary

What:

Spies have .verify(...).toBeCalledWithArgs(...). Mocks should use this logic in the .expects(...) method chaining.

Why:

Would be nice to create an expectation on a mock that a method was called with args.

Acceptance Criteria

Below is a list of tasks that must be completed before this issue can be closed.

  • Write documentation
  • Write unit tests
  • Write integration tests

Example Pseudo Code (for implementation)

const mock = Mock(...).create();

mock.expects("someMethod").toBeCalledWithArgs(...);

mock.verifyExpectations();

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