reduce code duplication in test_spidermiddleware_httperror
scrapy.utils.test.docrawl function
Fix for #612 + integration-style tests for HttpErrorMiddleware
TST fix file descriptor leak and a bad variable name in get_testlog
Merge pull request #656 from kmike/httperror-logging

[MRG] Fix for #612 + small tests cleanup