test for alarm() working properly to interrupt