They will tag the bags to JNB but you have to pick them up in CPT anyway, clear customs and then re-check them so it's all rather pointless. Unless the flights are delayed and you get rerouted (in which case you'll be glad the bags come to JNB directly).