mirror of
https://github.com/python/cpython.git
synced 2025-11-02 03:01:58 +00:00
Issue #25220: Create Lib/test/libregrtest/
Start to split regrtest.py into smaller parts with the creation of Lib/test/libregrtest/cmdline.py: code to handle the command line, especially parsing command line arguments. This part of the code is tested by test_regrtest.
This commit is contained in:
parent
e055b88937
commit
98de5340d4
4 changed files with 345 additions and 332 deletions
|
|
@ -7,7 +7,7 @@ import faulthandler
|
|||
import getopt
|
||||
import os.path
|
||||
import unittest
|
||||
from test import regrtest, support
|
||||
from test import regrtest, support, libregrtest
|
||||
|
||||
class ParseArgsTestCase(unittest.TestCase):
|
||||
|
||||
|
|
@ -148,7 +148,7 @@ class ParseArgsTestCase(unittest.TestCase):
|
|||
self.assertEqual(ns.use_resources, ['gui', 'network'])
|
||||
ns = regrtest._parse_args([opt, 'gui,none,network'])
|
||||
self.assertEqual(ns.use_resources, ['network'])
|
||||
expected = list(regrtest.RESOURCE_NAMES)
|
||||
expected = list(libregrtest.RESOURCE_NAMES)
|
||||
expected.remove('gui')
|
||||
ns = regrtest._parse_args([opt, 'all,-gui'])
|
||||
self.assertEqual(ns.use_resources, expected)
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue