Training your Pet is not something that anyone can give you a cookie cutter answer for how to best go about. There are a huge amount of options available, and you haven't even narrowed them down by telling us what type of Pet you have or intend to have and for what purposes.
Check Petopia for the skills your Pet is able to learn. If it can learn more than four "active" skills you need to first decide which to buy and which to skip. Unless you're training a Pet purely for a role as a raiding Hunter's added damage, you'll want to make one of those active skills Growl.
Buy Growl at the top level. It's free.
I'd suggest purchasing the top rank of either Bite or Claw, whichever your Pet can learn. Both skills are not necessary or even a good thing, but if you're BM and have both Bestial Discipline and Go For the Throat at max invested Talents, you can buy both.
If your Pet can learn either Dash or Dive, buy it at the top level.
If your Pet can learn a special ability such as Lightning Breath, Howl, Screech, Gore, etc., buy it at the top level. This is a bit simplistic, but if you've taken the time to tame a Beast which can learn these skills, then using them makes the most sense. Otherwise tame some other Beast. Put another way, there is no Pet which if it's special ability is skipped is such a good Pet as to be a compelling Pet even without that ability. Play to the strengths of the Pet.
Next buy Armor and Health. You probably won't have enough points to maximize both of these. I select Health over Armor because Pet armor is not terribly good at mitigation and does nothing against spells or other special damage. Health resists all forms of damage equally well.
Lastly, purchase resistances. This is actually something you need to determine before you buy your Health/Armor, but many people skip it entirely so it's safe to list it last. Resistances can be tailored to a favorite Instance, such as Fire Resist for MC/BWL, Nature Resist for AQ, etc. It can also be tailored for your play style. If you PvP a lot then some resistance to Nature, Frost, and Shadow will give your Pet a decent spectrum of defense against most snares and fear. If you're just looking to spend your few last points, I'd suggest Nature Resist as a decent option.
Specialization can help. For a long time I had a Bear for raiding, with maximized resistances for the Instances we were running, and a Cat or a Scorpid for PvP, each with different resists and trained unique Pet type abilities such as Scorpid Poison and Dash. I would take them depending on my role. If I was a flag guard I'd take the Scorpid, if I was on offense I'd take the Cat. Then I released the Cat and the Scorpid (and that Scorpid was a beautiful Silithus species, with glittering silver and light blue armor), tamed a Son of Hakar, and used it for PvP and the empty stable spot for training. The game isn't static, you can try lots of things and learn how they work best for you.
Let us know how you've decided to go with training your Pet(s).