added code to test for rally heuristic