Firstly June is mid-winter in South Africa; therefore it is low season and the weather will be at its worst. That being said I have travelled to SA twice at this time of year and the weather in CPT was (for a European like me) very pleasant. JNB will probably be quite cold though at that time of year.
As for CPT/JNB. I would keep JNB to no more than 2 (maybe 3) days. A must in the JNB area is the Apartheid museum. Also consider a tour of Soweto and possibly a side tour of Pretoria (40 mins by car). CPT is amazing and I would stay within the city or around Camps Bay. You can easily fill 4 or 5 days in the city alone. Do a tour of Robben Island, Cable Car up Table Mountain. Within an hour's drive of CPT is Cape Point and also Boulders Beach (for the Penguins). Nightlife in CPT is very good and I would recommend Long Street or the Bo Kap for restaurants. Also take High Tea at the Mount Nelson Hotel (delicious and hilarious at the same time!