#418 Revert changes in CBL_Shared and update unit test

* Per code review, revert changes in CBL_Shared back to use usleep instead of using NSRunLoop to wait.

* Update API_DeleteDatabase to ensure that the copied manager is closed and add test for the case that multiple managers working on different threads.