ticket:3 Tests
ticket:3 Fix tests
ticket:3 Working version
ticket:3 Added templates
Merge branch 't3_middleware'