added test for directive