test for reduce