Some fixes
Add tests for TTL, TDB and Repository