This is supposed to be used for all malformed queries and all the ones
that are invalid for incompatibility reason, and make sure that they
actually fail.
Require them to have assert rather than testing the
result variables set.
This makes for way simpler code.
Now also prints stacktrace to know where the problem occurred.
Python3 handles encoding differently, and files are loaded
according to the locale set on the system.
This means that when building on a locale-less chroot,
the tests will always fail because it will try to load utf-8
and encode it as ASCII.
This forces the encoding. The tests are encoded in utf-8 anyway
so any other encoding set by the locale would cause a failure.