tests and fixing bug within the loop returning a machine

when last time checked returned false it returned a machine falsely