Added support for entity inside embedded entity and some more test coverage.