Refactor Agent service class instantiation.

Any of our agent-specific BaseProtectedService subclasses have the exact
same instantiation code, coming from attributes of the DeploymentTarget.
It cleans up the mocking-style tests quite a bit and the implementations
a little to just have the DeploymentTarget handle instantiating any of
these classes for us.
Use mocking-style test for DeploymentTarget#refresh_metadata.

I have a full integration-style tests with webmock on the refresh
controller. This relied too much on a bunch of other parts of the
system.