added test to define macro function