My preference is to create additional Subs and limit the number of asserts per test (to one if possible).
If you only have a single Assert in each test Sub then when it fails it will be more obvious what the state is that causes the problem. If you have multiple Asserts in a single test Sub then determining which one caused the problem can be difficult.
You can use messages (the last parameter) to distinguish each of the Assert statements which will make things easier if you want to have multiple Asserts in a single Sub. You should be aware that if you do this the first one that fails will end the test and any subsequent asserts will not be evaluated.
|