added karma unit test
added karma unit test