How to test to see if a program is running?