Fix NTL interface test code.

Reported by Francois Bissey.

I hate the pull request interface, only the last commit is actually needed.
The other ones are merge commmits or have already been merged by Bill.