Fixed input handling for the test program chooser.