Skip to content

Instantly share code, notes, and snippets.

What would you like to do?
Anatomy of a Unit Test
import test from 'tape';
// For each unit test you write,
// answer these questions:
test('What component aspect are you testing?', assert => {
const actual = 'What is the actual output?';
const expected = 'What is the expected output?';
assert.equal(actual, expected,
'What should the feature do?');

This comment has been minimized.

Copy link

terkelg commented Jul 27, 2016

Thanks, Super helpful!
For those who didn't come here directly from the article, you should check it out:
5 Questions Every Unit Test Must Answer

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.