[orm] refactor SQL loggers to common ORMDbTestCase SQL logging feature
[orm] All tests up to date + code style fixes
[orm] Clean up TODO, fix some assetrions