fixed test loop