South Africa take revenge of the dismal Test series