We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Trying to perform Mock.Of of a interface with a multidimensional array fails.
Interface:
public interface I2DShape { int[,] Data { get; } int Rows { get; } int Columns { get; } }
Failing code
Mock.Of<I2DShape>();
Constructor on type 'System.Int32[,]' not found.
Workaround
var shapeMock = new Mock<I2DShape>(); shapeMock.SetupGet(x => x.Data).Returns(new int[0, 0]);
The text was updated successfully, but these errors were encountered:
Thanks for implementing this
Sorry, something went wrong.
You're welcome!
stakx
No branches or pull requests
Trying to perform Mock.Of of a interface with a multidimensional array fails.
Interface:
Failing code
Workaround
The text was updated successfully, but these errors were encountered: