Pulls routes out into a submodule

Refactors plugin.py and associated tests to pull routes out into their
own submodule for improved plugin readability.