Fixes BZ 1098223 -- repo deletion does not work in some cases.

If the relative path contains a trailing slash, then the symlink deletion would fail. Symlinks are considered files not directories, and a trailing slash causes the symlink to get treated as a directory. The docs do not encourage a trailing slash when the user specifies the relative url, but it does work, so smartening up the deletion is how I've decided to fix this.

I've adjusted a test which needed updating because of the change. That update provides an assertion of the new lines introduced.