After a bunch of research, it appears this is not possible, but I'm hoping someone here has found a way.
I am using a before update trigger on Opp to call a class which contains a future method with an HTTP callout. It all works fine. But in the test class, Limits.getCallouts() always returns 0.
Test.startTest();
update Opportunities;
Integer callouts = Limits.getCallouts();
system.debug('Callouts = '+callouts);
Test.stopTest();
The debug always shows 0, even though the debug log also shows that the callout was indeed made. I am successfully getting the response from my mock callout class.
USER_DEBUG [29]|DEBUG|Successful message sent, response: Thanks for all the fish!
USER_DEBUG [39]|DEBUG|Callouts = 0
This is always the case, whether I put the debug before stopTest, after stopTest, or even if I don't use start/stopTest at all.
How can one ever test the number of callouts they've made in a test class?