So sure, we all watched the Democratic debate like it was a normal debate, but let’s face facts: It was ­really just a two-hour competency test for Joe Biden at pretty much the last moment before the ex-veep’s nomination became ­inevitable.

And that test he passed with flying colors — even though he laid several long-term traps for himself in the general election battle with President Donald Trump.

With the exception of a few minutes during which Bernie Sanders threw Biden back on his heels with an aggressive assault on his truthfulness about Social Security cuts, the former Uncle Joe was surprisingly, even shockingly, in command.

Even more important, when it comes to the coronavirus, Biden kept hammering home the same point — that we need to deal with the crisis right now, with policies to mitigate and address the potential blows to the health-care system and the coming economic shocks and dislocations for tens of millions of Americans.

Sanders, who clearly wanted to use the virus to advance his larger cause, pushed for single-payer health care. Biden responded by pointing out that “you have a single-payer system in Italy. It doesn’t work there.”

Biden said “we are at war with the virus,” and even suggested using the military if necessary to help with the response. “First things first,” he declared, effectively arguing that you don’t discuss reforming building codes when you’re getting ready to fight the Chicago fire.

His toughest jab at the Vermont socialist was a simple one-liner: “People are looking for results, not revolution.” Sanders was, I think, so startled by his rival’s ­coherence that he wasn’t listening closely enough to how Biden’s rhetoric on the virus response closely tracked his own.

In effect, Biden was calling for nationalized health care — but just in dealing with the virus. No one, he said, should have to pay for coronavirus treatment.

Biden moved toward Sanders’ radical views several times during the debate, which was an interesting choice, since his relatively significant lead in delegates and enthusiasm might have suggested it was time for Biden to pivot ­toward the center.

Instead, he said he would institute a 100-day ban on deportations if he became president and would not insist that local police turn over arrested illegals to the federal Immigration and Customs Enforcement agency.

When it came to energy policy, Biden said he would ban “all new fracking.” And here we have an example of the long-term trouble he might have caused himself.

That stance is a more moderate position, perhaps, than Sanders’ vow to end all hydraulic fracturing immediately. But Biden ­expressing deep antipathy toward the innovations that have brought new life to the economy in the critical swing state of Pennsylvania, just to take the most potent example among many others, is a giant substantive gift to Trump in the general election.

As for the big news events of the debate — Biden first saying he would appoint a black woman to the Supreme Court and then that he would name a woman as his running mate — they all but ensured whatever Sanders was trying to do or accomplish would be overshadowed.

At one point, Sanders actually tried to conduct a debate with Biden in which he sought to have his rival acknowledge the great economic achievements of Chinese Communism — which just seems like a bizarre tack to take at this moment of all moments.

It fit in with Sanders’s overall ­effort to say that he is the same person he has always been and ­unafraid to take unpopular positions because that’s what leadership is. In other words, he’s a Commie, and he’s always been a Commie and will always be a Commie.

If the country turns on Trump in November, the unexpected wipeout of Sanders in North Carolina and Super Tuesday might look like the most providential political event since Franklin Delano Roosevelt dropped his Russophilic Vice President Henry Wallace from the ticket in 1944 in ­favor of Harry Truman.

Sanders looked for a minute like he had the nomination in the bag. And then — poof!

Thank God.