I'm new to unit testing, and I'm learning how to use NUnit and Moq. NUnit provides Assert
syntax for testing conditions in my unit tests, while Moq provides some Verify
functions. To some extent these seem to provide the same functionality.
How do I know when it's more appropriate to use Assert
or Verify
?
Maybe Assert
is better for confirming state, and Verify
is better for confirming behavior (Classical versus Mockist)?