dmocks.dynamic(19): Assertion failure for returns(null)
linkrope opened this issue · 0 comments
linkrope commented
interface Dependency
{
string foo();
}
unittest
{
auto mocker = new Mocker;
auto dependency = mocker.mock!Dependency;
mocker.expect(dependency.foo).returns(null);
mocker.replay;
assert(dependency.foo is null);
}
A workaround would be returns(cast(string) null)
.