Add unit tests for query menu item directive