When writing unit tests, it is usually recommended to check edge cases.
However, are they the right thing?
- Check that the connection to db is not open (it is claimed that an exception is thrown)
- Assert that a table that should always have> 1 row does this
- Assert that the field that is required is! = Null.
- Confirm that ip was installed in the correct format (I can parse the string to IP).
thank
source
share