wrote some tests and create possibility to store debug data in db models