mirror of
https://github.com/django/django.git
synced 2025-10-24 06:06:09 +00:00
Refs #33476 -- Reformatted code with Black.
This commit is contained in:
committed by
Mariusz Felisiak
parent
f68fa8b45d
commit
9c19aff7c7
@@ -2,19 +2,28 @@ from django.test.runner import DiscoverRunner
|
||||
|
||||
|
||||
class CustomOptionsTestRunner(DiscoverRunner):
|
||||
|
||||
def __init__(self, verbosity=1, interactive=True, failfast=True,
|
||||
option_a=None, option_b=None, option_c=None, **kwargs):
|
||||
super().__init__(verbosity=verbosity, interactive=interactive, failfast=failfast)
|
||||
def __init__(
|
||||
self,
|
||||
verbosity=1,
|
||||
interactive=True,
|
||||
failfast=True,
|
||||
option_a=None,
|
||||
option_b=None,
|
||||
option_c=None,
|
||||
**kwargs,
|
||||
):
|
||||
super().__init__(
|
||||
verbosity=verbosity, interactive=interactive, failfast=failfast
|
||||
)
|
||||
self.option_a = option_a
|
||||
self.option_b = option_b
|
||||
self.option_c = option_c
|
||||
|
||||
@classmethod
|
||||
def add_arguments(cls, parser):
|
||||
parser.add_argument('--option_a', '-a', default='1'),
|
||||
parser.add_argument('--option_b', '-b', default='2'),
|
||||
parser.add_argument('--option_c', '-c', default='3'),
|
||||
parser.add_argument("--option_a", "-a", default="1"),
|
||||
parser.add_argument("--option_b", "-b", default="2"),
|
||||
parser.add_argument("--option_c", "-c", default="3"),
|
||||
|
||||
def run_tests(self, test_labels, **kwargs):
|
||||
print("%s:%s:%s" % (self.option_a, self.option_b, self.option_c))
|
||||
|
||||
Reference in New Issue
Block a user