Add support for adding a project while an old project with same name exists.
This could happen because old project might still have references. Add tests
for this along with test code refactoring

Change-Id: I021a662445167a7ef9b6b95d4dc642c1e510382e
(cherry picked from commit 22f62fef8e6fac45b04028c803775cbdcb4fe1c4)
Merge "Add support for adding a project while an old project with same name exists. This could happen because old project might still have references. Add tests for this along with test code refactoring" into R1.10