Unit testing asynchronous processes

T

Tim Chase

I've got some code that kicks off a background request to a remote
server over an SSL connection using client-side certificates. Since
the request is made from a separate thread, I'm having trouble testing
that everything is working without without spinning up an out-of-band
mock server and actually making all the request. Are there some best
practices for testing/mocking when things are asynchronous and
involve SSL connections to servers?

I'm currently just ignoring the SSL/client-cert thing and trusting my
calls work. But I'd like to at least have some tests that cover these
aspects so that things don't fall through the cracks.

Thanks,

-tkc
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

Forum statistics

Threads
473,744
Messages
2,569,483
Members
44,901
Latest member
Noble71S45

Latest Threads

Top