Metro police chief David Tembe said the officers had received a complaint from a school where "these ladies were selling outside its premises".
"When the ladies were confronted by the officers, they swore, even assaulting our officer," said Tembe.
The two were immediately arrested.
Tembe said the pair was charged with crimen injuria, assaulting an officer and contravention of street trading bylaws.
Their arrest came on the same day that more than 170 pupils from Nomini Primary School in Orange Farm had to be taken for medical treatment after falling ill, allegedly due to sweets they had bought from a vendor.
The Gauteng health department said the children were sent to various hospitals after complaining of stomach cramps and vomiting.