zpm: abstract the swift_url construction logic

This moves the construction of the swift_url (for the .zar, which looks
like "swift://AUTH_abcdef.../test_container/myapp.zar") to a seperate
util function--with doctests, for good measure.