neel
neel

Reputation: 5293

Mock reference in Visual Studio 2012

hi i am doing unit testing of entity framework with repository pattern. I just try to mock a repository class in my test project

private Mock<IStudentRepository> repositoryMock;  

and i am using the namespace

 Using Moq;    // is that correct????????

but the assembly reference/directive is missing error shows, so i try to add references, but i cant understand which is assembly reference/directive of Moq. Can anybody please help me

Upvotes: 0

Views: 3280

Answers (1)

dave
dave

Reputation: 2371

Try to define the "using" in lowercase.

Make sure that you have referenced the Moq library in your project. You could use NuGet to get it:

Install-Package Moq

Upvotes: 8

Related Questions