Unit testing is not as simple as it seems...
You get various types of unit testing.
To mention a few:
DO-178B Level A -> Branch Coverage + Statement Coverage + Boolean Coverage (MCDC)
DO-178B Level B -> Branch Coverage + Statement Coverage
DO-178B Level D -> Statement Coverage Only
That is just from the DO-178B Standard
There are various standards around.
Requirements Testing is where you test your software requirements and afterwards check your coverage to see whether there are code in your software which doesn't link to a requirement. In the process testing whether the requirements do what they say they do.
A typical software requirement will read: "The function shall open the main form."
You wil typically set your input data (input parameters/or whatever), or setup your initial data to a closed main form, call the Unit Under Test (Function Under Test) and after the function executed, verify your input_data Vs you expected_data.
The field is wide and you get many different methods of testing.
Example:
Form obj = new Form();
obj.setVisible(false);
EnableMainForm(obj);
assert(obj.getVisible(), true);
Say that EnableMainForm had only one requirement but was doing a whole bunch of other things aswell not documented/linked to a requirement, your code coverage would show just that and you could log a bug for that reason.