Cook, Hameed make history in India Test