refactor the directive v-pager.
added tests for exceptions.