Category model generated and added validation and association tests.
Category model
Removed unneeded code.