Refactor filtering of sidebar modules to helper.

Also strip out modules with empty bodies.
Setup for testing with spork and minitest.
Add tests for sidebar helper.

Also fixes DOM id of sidebar modules with spaces in their title.