updates to fix a test and provide a dependency injection for a directive