tests/parsetext: make the helper functions static