Skip to content

Instantly share code, notes, and snippets.

@jonathascosta
Created January 15, 2013 18:08
Show Gist options
  • Save jonathascosta/4540583 to your computer and use it in GitHub Desktop.
Save jonathascosta/4540583 to your computer and use it in GitHub Desktop.
Unit test snippet
<?xml version="1.0" encoding="utf-8" ?>
<CodeSnippets xmlns="http://schemas.microsoft.com/VisualStudio/2005/CodeSnippet">
<CodeSnippet Format="1.0.0">
<Header>
<Title>Test case</Title>
<Shortcut>testcase</Shortcut>
<Description>Test case method</Description>
<SnippetTypes>
<SnippetType>Expansion</SnippetType>
</SnippetTypes>
</Header>
<Snippet>
<Declarations>
<Literal>
<ID>methodName</ID>
<Default>Test</Default>
<ToolTip>Method name</ToolTip>
</Literal>
</Declarations>
<Code Language="csharp">
<![CDATA[
[Test]
public void $methodName$() {
var expected = 1;
var actual = 1;
Assert.AreEqual(expected, actual);
}
]]>
</Code>
</Snippet>
</CodeSnippet>
</CodeSnippets>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment