Is there a way to pass a handler/function pointer as a script parameter?
I am finding that I am cutting and pasting a lot of code from script to script and it’s making me very nervous.
Basically, what I have is a script to test a lot of very similar functionality in our applications. If I could pass in a function pointer to the base script with a specific path of execution to follow and another pointer to the verification function that will verify everything worked or not I could reduce or maybe eliminate my cut and paste problem.
To date I haven’t figured out a way to do this, never mind passing a variable length collection of them.
I thought about a very long if else construct but I don’t think I like that idea any better than the cut and paste option.
Maybe someone out there knows how to do it or has a better way? (timtowtdi)