Fall back to non-locked tests on systems without interprocess locking permission (eg. Travis).
This commit is contained in:
parent
44679d8a7f
commit
6081021a24
1 changed files with 5 additions and 1 deletions
|
@ -54,8 +54,12 @@ class _ComicTester(TestCase):
|
|||
scraperobj = self.scraperclass()
|
||||
# Limit number of connections to one host.
|
||||
host = get_host(scraperobj.url)
|
||||
try:
|
||||
with get_lock(host):
|
||||
self._test_comic(scraperobj)
|
||||
except OSError:
|
||||
# interprocess lock not supported
|
||||
self._test_comic(scraperobj)
|
||||
|
||||
def _test_comic(self, scraperobj):
|
||||
num = 0
|
||||
|
|
Loading…
Reference in a new issue