Fix tests to work with recent versions of Teng