New Zealand end 36-year wait for Test win in India