Skip to content

Mock delegate with functional style causes infinite loop #224

@davidshen84

Description

@davidshen84
var deleMock = Mock.Of<SomeDelegate>();

Mock.Get(deleMock).Setup(f => f()).Returns("something");

The above code works.

But with functional style:

var deleMock = Mock.Of<SomeDelegate>(f => f() == "something");

Cause the test stop at the line infinitely.

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions