mirror of
https://github.com/Mikaela/Limnoria.git
synced 2025-01-24 02:54:05 +01:00
SedRegex: skip testReDoSTimeout if multiprocessing is disabled
This commit is contained in:
parent
a6ae9f51a3
commit
d3b991895c
@ -1,5 +1,5 @@
|
|||||||
###
|
###
|
||||||
# Copyright (c) 2017-2019, James Lu <james@overdrivenetworks.com>
|
# Copyright (c) 2017-2020, James Lu <james@overdrivenetworks.com>
|
||||||
# All rights reserved.
|
# All rights reserved.
|
||||||
#
|
#
|
||||||
# Redistribution and use in source and binary forms, with or without
|
# Redistribution and use in source and binary forms, with or without
|
||||||
@ -29,6 +29,7 @@
|
|||||||
###
|
###
|
||||||
|
|
||||||
from __future__ import print_function
|
from __future__ import print_function
|
||||||
|
import unittest
|
||||||
from supybot.test import *
|
from supybot.test import *
|
||||||
|
|
||||||
class SedRegexTestCase(ChannelPluginTestCase):
|
class SedRegexTestCase(ChannelPluginTestCase):
|
||||||
@ -173,6 +174,7 @@ class SedRegexTestCase(ChannelPluginTestCase):
|
|||||||
m = self.getMsg(' ')
|
m = self.getMsg(' ')
|
||||||
self.assertIn('Segmentation fault (core dumped)', str(m))
|
self.assertIn('Segmentation fault (core dumped)', str(m))
|
||||||
|
|
||||||
|
@unittest.skipIf(world.disableMultiprocessing, "Test requires multiprocessing to be enabled")
|
||||||
def testReDoSTimeout(self):
|
def testReDoSTimeout(self):
|
||||||
# From https://snyk.io/blog/redos-and-catastrophic-backtracking/
|
# From https://snyk.io/blog/redos-and-catastrophic-backtracking/
|
||||||
for idx in range(500):
|
for idx in range(500):
|
||||||
|
Loading…
Reference in New Issue
Block a user