add a test for multi-thread