example of separating model and controller logic using simple Ruby; simple unit tests included