Code Cleanup

Moved metrics and request wrapper to lib/metrics module
Moved puppet functions to lib/puppet module
Added a few tests for routes/tickets.js