All of the stats will increase as if it had always been rare. When you upgrade quality, the stats automatically increase/upgrade regardless of the pets level.
And it is true that the stats increase when quality is higher / upgraded. For example....
Perky Pug is uncommon by default. If you level it to 25 as uncommon it shows the following stats:
1225 Health, 297 Power, 252 Speed
If you were to stone it at level 25, it would show the following increased stats:
1319 Health, 322 Power, 279 Speed
Hope that helps