Added two tests proving issue 3011. The tests create a connection between two objects and tries to delete the entities associated with the connection without disbanding the connection.