I am nonnative speaker & I often ask a lot of questions that native people have never thought about.
Ok, this site says:
"Couldn't have" is used to show someone's feeling that something in the past is impossible.
You couldn't have seen Jerry yesterday. He's been out of town since last Tuesday!
(It's impossible for you to have seen Jerry yesterday because he wasn't here. He's been out of town since last Tuesday!)
So, "someone's feeling" is a guess right? Because if that actually happened, then you use "Couldn't do" right?
Let say I am a very lazy student
Case 1: if I actually failed the test (I got the result in front of my eyes yesterday), I would say: "I couldn't pass the test yesterday" (It was a fact in the past)
Case 2: I took the test yesterday & I will get the result tomorrow, I would say: "I can't pass the test" (I think about the future)
Case 3: I had took the test & the result came out yesterday but I have not checked it (ie I have not officially known I failed), I would say: "I couldn't have passed the test"
I am not sure my thinking is right or not.
But some people said we could say "I couldn't have passed the test" even we have not known the result. That means I did take the exam, I will get the result tomorrow, but I can still say "I couldn't have passed the test" .
Modal verbs are the hardest English stuff I ve ever learned.