- added the "process_sp->GetExtendedThreadList().AddThread (new_thread_sp);"
line when the ThreadSP is created, and also added this into the test case
- refactored the duplicate code into a CreateHistoryThreadFromValueObject function that is called twice.
Please split into two lines,