Implemented unit test for setting relation references