Add spec tests.

This adds tests for all elements we can create during regular
parsing. This also adds tests for text with unicode in it.