test a function