Tolerate trailing comments when checking for DEFAULT section

The previous patch didn't allow for a trailing comment on the same
line as the default section.  This patch tolerates trailing comments
and whitespace.

I added two new tests to ensure that the DEFAULT section line isn't
duplicated when we have trailing whitespace or trailing comments.
To avoid the need to renumber all of the test comments whenever new
tests are inserted, the test output has been modified to report the
test script line number when outputting the "ok" and "fail" status.
It still seems valuable to have an incrementing test counter just
for the purpose of knowing how many tests there are, so I left that
in the test output.