vendredi 31 juillet 2015

How to Unit Test Methods with Sharepoint Objects as parameters with Microsoft Fakes

Im trying to write a unit test for methods that take sp objects as parameters like SPWeb or SPEventReceiverCollection etc. with Microsoft Fakes but have no idea how to mock these. I've used moq before but cant seem to find how to Mock in microsoft fakes. eg:

public List<SPEventReceiverDefinition> CheckExisting(SPEventReceiverDefinitionCollection recs)

Aucun commentaire:

Enregistrer un commentaire