Add checking main thread methods to ThreadUtils