adding tests and another EntityExtractor fix