fix bugs in LexerContractTest introduced by last commit