added tests and functionality for js tests and ordinary annuities