By my reading of the linked article, a well boosted Temple of Valor should simply cause all invasions to fail, because 100% of the attacking legions will be destroyed before ever reaching the planet? Edit: it appears my confusion is a result of the tooltip information being incorrect. I have a Temple of Valor with +6 in adjacency bonuses. When my mouse is over the improvement, the tooltip says being level 6 provides an additional +300% to planetary defense. When my mouse is over the planetary defense stat summary in the bottom section, it merely lists the Temple as providing its base 25%, along with 10% from the fortification technology.
Edit: however, it appears an invincible planet may still be possible with a *very* well boosted Ancient Defense System, presumably in combination with the handful of other planetary defense boosters. Or multiple ADFs, if you're willing to use the bug that allows you to build player wonders. Give away the planet containing an ADF via diplomacy, and you'll be allowed to build another ADF. Culture flip your original ADF back to yourself, then give it away again to build yet another ADF. Repeat as often as desired. This works with all player wonders as far as I'm aware.