Refactored URL generation to a testable method.
mocked getvehicles
mocked getroutes
mocked getpatterns
Fully mocked, starting on unit tests.