Wrote some better tests

Still learning the best way to apply tests
Fixed link text error when a defined section heading is the first child of the article

Loving unit testing already, never would have found this error