tests only: fixing an error when thread_ui_test.js runs on its own due to lack of mock. a=npotb