A web application I'm developing essentially serves to queue up jobs which are processed on another server. Depending on the load, that could be anywhere from 5 minutes to 2 hours later before the results are returned and stored. I'm trying to think of the best way to architect some integration testing of the site. This wouldn't be on the production site so I can manage how many jobs are loaded at once which will make things more predictable and timely. I'm just wondering if there are any good resources regarding best practices for this kind of situation and any pitfalls since essentially a test could be sitting and waiting for an hour for results.