Category Archives: SharePoint

Straight Out of ADC 2011

ADC2011 is over, and I had a mighty fun time. Like I open my talks, I’d like to speak first on my favorite subject: me. I had two talks, one on unit testing SharePoint applications, and the other about tools for identifying issues in multithreaded apps (slides below). I can tell you that all those

Read More

Battle of the framework: Testing a Webpart

Time to see the difference between Moles and Isolator code. Let’s start with the code under test (a webpart): public class NewMessagesCountWebPart : WebPart{    private Label lblNewMessages;    protected void CreateChildControls(int i)    {        CreateChildControls();    }       protected override void CreateChildControls()    {        lblNewMessages = new Label();        lblNewMessages.Text = GetMessageNumberText();        this.Controls.Add(lblNewMessages);        base.CreateChildControls();    }    private string GetMessageNumberText()    {        using (SPSite site = new SPSite(“”))        {            using (SPWeb web

Read More

Battle of the frameworks: The SharePoint arena

Last week, I gave a presentation at the Israeli SharePoint user group on unit testing SharePoint applications. Slides below. Me closer (lurking in the shadows). As an objective observer, I compared the two and only alternatives for Isolation frameworks for SharePoint: Typemock Isolator and Microsoft Moles. And here’s my objective decision: Isolator wins by a

Read More