forced input to be an integer

also made the test stop when a new integer is entered