KnowledgeHub
Questions
Tags
Users
Search
Alex Rivera
|
Logout
Edit Question
Title
Body
Is having more than one assert per test a really bad smell? I usually try to follow the “arrange, act, assert” pattern as well as the single assert per test guideline. I think having clean, small, isolated tests is pure awesomeness. For the most part I manage to do this. However, sometimes I find myself asserting “pre-conditions” right after my arrange like so: 'arrange: 'pre-conditions: Assert the arrange worked 'act: 'assert: Is my test testing too much? Is it caring about things it shouldn’t care about? I’d love to hear some opinions on this.
Tags (comma-separated)
Save Edits
Cancel