<?xml version="1.0" encoding="UTF-8" ?>
<?xml-stylesheet type="text/xsl" href="http://blogs.msdn.com/utility/FeedStylesheets/rss.xsl" media="screen"?><rss version="2.0" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:slash="http://purl.org/rss/1.0/modules/slash/" xmlns:wfw="http://wellformedweb.org/CommentAPI/"><channel><title>Matt Manela's Blog : Snippets</title><link>http://blogs.msdn.com/matt/archive/tags/Snippets/default.aspx</link><description>Tags: Snippets</description><dc:language>en-US</dc:language><generator>CommunityServer 2.1 SP1 (Build: 61025.2)</generator><item><title>My xUnit.net Visual Studio Code Snippets</title><link>http://blogs.msdn.com/matt/archive/2009/03/02/my-xunit-net-vs-code-snippets.aspx</link><pubDate>Tue, 03 Mar 2009 02:58:00 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:9455475</guid><dc:creator>MattManela</dc:creator><slash:comments>1</slash:comments><comments>http://blogs.msdn.com/matt/comments/9455475.aspx</comments><wfw:commentRss>http://blogs.msdn.com/matt/commentrss.aspx?PostID=9455475</wfw:commentRss><description>&lt;P&gt;The &lt;A href="http://xunit.codeplex.com/" mce_href="http://xunit.codeplex.com/"&gt;xUnit .Net&lt;/A&gt; codeplex page &lt;A href="http://xunit.codeplex.com/Wiki/View.aspx?title=VsSnippets" mce_href="http://xunit.codeplex.com/Wiki/View.aspx?title=VsSnippets"&gt;lists one&lt;/A&gt; useful Visual Studio code snippet for creating a Fact.&amp;nbsp; As you &lt;A href="http://snippetdesigner.codeplex.com/" mce_href="http://snippetdesigner.codeplex.com"&gt;can tell&lt;/A&gt; I am fairly fond of code snippets so I created a few more which I use when writing xUnit.net facts. These are one line snippets that I find very convenient when writing my assertions.&lt;/P&gt;
&lt;P&gt;Below is a table which shows the shortcut you use to access the snippet and the code the snippet generates&lt;/P&gt;
&lt;TABLE border=0 cellSpacing=0 cellPadding=2 width=362&gt;
&lt;TBODY&gt;
&lt;TR&gt;
&lt;TD vAlign=top width=90&gt;&lt;STRONG&gt;Shortcut&lt;/STRONG&gt;&lt;/TD&gt;
&lt;TD vAlign=top width=270&gt;&lt;STRONG&gt;Snippet&lt;/STRONG&gt;&lt;/TD&gt;&lt;/TR&gt;
&lt;TR&gt;
&lt;TD vAlign=top width=90&gt;ae&lt;/TD&gt;
&lt;TD vAlign=top width=270&gt;Assert.Equal($expected$,$actual$)&lt;/TD&gt;&lt;/TR&gt;
&lt;TR&gt;
&lt;TD vAlign=top width=90&gt;ane&lt;/TD&gt;
&lt;TD vAlign=top width=270&gt;Assert.NotEqual($expected$,$actual$)&lt;/TD&gt;&lt;/TR&gt;
&lt;TR&gt;
&lt;TD vAlign=top width=90&gt;an&lt;/TD&gt;
&lt;TD vAlign=top width=270&gt;Assert.Null($actual$)&lt;/TD&gt;&lt;/TR&gt;
&lt;TR&gt;
&lt;TD vAlign=top width=90&gt;ann&lt;/TD&gt;
&lt;TD vAlign=top width=270&gt;Assert.NotNull($actual$)&lt;/TD&gt;&lt;/TR&gt;
&lt;TR&gt;
&lt;TD vAlign=top width=90&gt;at&lt;/TD&gt;
&lt;TD vAlign=top width=270&gt;Assert.True($actual$)&lt;/TD&gt;&lt;/TR&gt;
&lt;TR&gt;
&lt;TD vAlign=top width=90&gt;af&lt;/TD&gt;
&lt;TD vAlign=top width=270&gt;Assert.False($actual$)&lt;/TD&gt;&lt;/TR&gt;&lt;/TBODY&gt;&lt;/TABLE&gt;
&lt;P&gt;I have included a &lt;A title="xUunit.net Snippets" href="http://blogs.msdn.com/matt/attachment/9455475.ashx" mce_href="http://blogs.msdn.com/matt/attachment/9455475.ashx"&gt;zip containing these snippets&lt;/A&gt;.&amp;nbsp;&amp;nbsp; Enjoy!&lt;/P&gt;&lt;img src="http://blogs.msdn.com/aggbug.aspx?PostID=9455475" width="1" height="1"&gt;</description><enclosure url="http://blogs.msdn.com/matt/attachment/9455475.ashx" length="3703" type="application/x-zip-compressed" /><category domain="http://blogs.msdn.com/matt/archive/tags/C_2300_/default.aspx">C#</category><category domain="http://blogs.msdn.com/matt/archive/tags/Visual+Studio/default.aspx">Visual Studio</category><category domain="http://blogs.msdn.com/matt/archive/tags/Snippets/default.aspx">Snippets</category></item></channel></rss>