cvan/galaxy-api — pull request #188 by soedar (2014-04-16 18:40:49+00:00)
Title: Refactor feedback lib, and added unit tests

I was starting to write tests for the feedback lib, and I realize that we can't really test the setters only. So I did some refactoring, and added getters (to get the list of feedback).

Main changes:
1. The `newFeedback` function now checks for valid user id
2. Added 2 'helper' function that adds feedback anonymously or by the user's email
3. In redis, we now key the feedback set using the page url (eg: `feedback:http://galaxy.mozilla.com/games`). Also there is a key `feedbackKeys` which is a set that stores all the keys that has at least 1 feedback.
4. Added getters to get the feedback for a particular page url.

Juicy unit tests included. :yum:

r? @cvan @birkanu @yangshun