Fix IsValidDirectionChangeTest() method