Refactor routes test into setup/teardown phases

Review Request #10050 — Created June 29, 2018 and submitted

Information

rb-gateway
master
9b5bb5b...

Reviewers

Since all the routes tests do the same common setup and tear down, they
have been refactored to call a method which returns all the common data
used in the tests (repositories, config instance, etc.) and a way to
tear it down.

We now also pass config.Config objects by their address since they
contain pointer types (specifically the Repositories field) to make it
clear that any function receiving them may modify them. Previously it
was possible to modify their pointer fields even if passed by value.

Ran go fmt ./....
Ran make test.
Ran make integration-tests.

david
  1. Ship It!
  2. 
      
brennie
Review request changed
Status:
Completed
Change Summary:
Pushed to master (788a320)