can you add a test in thread_ui_test.js too ? the `createThread` function should be quite easily testable with what we already have in that test file