Add tests for RelayThread setup