Angular JS functionality test