Added tests for looping around a user function