fixed minor bugs. added tests for model entity
made stream scroll to bottom on message receiving