Add a way to do mocking for Tor unit tests
Right now, one of our biggest obstacles to improved test coverage is the fact that we don't have a good way to mock functions during C testing.
There are a big pile of mocking tools for C, but they mostly suck and either want you to split your code up weirdly, litter it with macro salad, or such.
There's another class of solution based on preprocessing C or postprocessing assembly, but both approaches are fragile, and we'd probably need to polish or maintain whatever tool we wound up using. Not a great situation to be in. I've maintained compiler wrappers. (It was a bad scene, man.)[http://www.pmg.csail.mit.edu/polyj/]
Still, our current low test coverage is worse still; worse even than macro salad; worse even than magic compiler wrappers. So we ought to bite the bullet and figure out the least difficult and least awful option and do it.
(Please don't just post the results of a search on "c mocking tools" or "c unit testing" here: I can do that search too.)