Remove trailing characters from pgtap script.