main test loop broken?