Fix the webkitpy URLs to the layout test results in googlestorage.

This should unbreak rebaseline-o-matic and the other python tools.
garden-o-matic and the flakiness dashboard already had this right
(in JavaScript).

This also de-dups some of the URL-forming code and adds tests.

R=ojan@chromium.org
BUG=261719

Review URL: https://chromiumcodereview.appspot.com/23434007

git-svn-id: svn://svn.chromium.org/blink/trunk@157323 bbb929c8-8fbe-4397-9dbb-9b2b20218538