tdlib wrapper hacks

This is only used to run old tests. Don't use in new code.
