If you have a known good (local) and known bad (remote), the first thing I'd probably do is run diff on the local and remote logs. Use a regex or something to strip timestamps or similar that will always differ.
If your tests take 20–30 minutes to run, I think that I'd look into having a way to run a subset of the tests, so you can just run the minimal amount to do the failing one.
If you have a lot of environment problems, I think I'd focus on getting an automated build of the environment to a standard state. If that takes too long, setting up caching or whatever of downloaded packages.