Re-factor delete node logic & updated test
Updated set child logic to make sure patent object pointing to correct 
object
Corrected delete logic.
Updated test for delete logic
Correct delete logic & tests
Change logic of parent reference during child reference set