Interesting. You are correct, presuming South Africa had beaten Tonga with a bonus point as they would be clear winners.
A bizarre and unlikely outcome is if Scotland beat us and we both get bonus points!
For then all three are equal on 15 points and on the first tie break criterion; Ireland would be better than South Africa would be better than Scotland would be better than Ireland
We would then move on to the second tie break condition - points difference which would likely see us with best PD then SA then Scotland.