The Nazis actually had a plan for the invasion of Switzerland called Operation Tannenbaum. There were several reasons they decided not to invade, and Swiss military prowess was only one of the reasons. The fact that Hitler had bigger fish to fry, such as invading Russia and England, and was already getting most of what he wanted from the Swiss were the leading reasons he left Switzerland alone. You can find an overview of those reasons here:
Operation Tannenbaum at AllExperts