Foxes avoid dogs, even small dogs, because many Foxes are killed by dogs.
So it is much more likely that your dog will attack the fox, not the other way round.
Attacks on cats are equally rare: cats and Foxes are roughly the same size, and cats are very capable of defending themselves against foxes.