I’m afraid that is not true.
https://en.m.wikipedia.org/wiki/Starfish_Prime
“The explosion took place at an altitude of 250 miles (400 km), above a point 19 miles (31 km) southwest of Johnston Atoll.”
That’s roughly the same altitude the international space station flies at.
PTBT happened in the early 60s, so almost all surface tests were conducted within the first twenty years of developing nukes. I don't think making "craters" in desert mines really qualifies as enormous destruction of habitats.
But the fact that the PTBT was signed by most nuclear states which slowed down this pointless destruction—and later the CTBT, which almost stopped it in 1997—shows that even humans with our demonstrable aggressiveness do work to limit our destruction when said destruction doesn’t contribute to the enrichment of a subset of other members of the species.
Humans are the most aggressive species we know of capable of mass destruction. We would (and do) certainly destroy other species to get some resources in order to enrich a small but highly privileged portion of our population. However—despite our aggression—we would not destroy an alien world at the mere sight of it without any prospects for profit.
Our most destructive era was probably the era of nuclear missile testing. It certainly did an enormous needless destruction of non-human (and human) habitat. This era only lasted a couple of decades and ended with a comprehensive test ban in the 1990s. Despite our capabilities we never tested these weapons of horror in space or on alien planets, and we probably never will.