diff options
author | Ezio Melotti <ezio.melotti@gmail.com> | 2012-10-02 16:45:00 (GMT) |
---|---|---|
committer | Ezio Melotti <ezio.melotti@gmail.com> | 2012-10-02 16:45:00 (GMT) |
commit | 3ffd29b6153aa24ccb943ca92373eb5785118ef8 (patch) | |
tree | b4f17878e31aceb5daf04d0a37c05041509047a2 /Lib | |
parent | 3f459ecc6a9a3840d68288b7774de81b39ed1b71 (diff) | |
download | cpython-3ffd29b6153aa24ccb943ca92373eb5785118ef8.zip cpython-3ffd29b6153aa24ccb943ca92373eb5785118ef8.tar.gz cpython-3ffd29b6153aa24ccb943ca92373eb5785118ef8.tar.bz2 |
Remove unnecessary [].
Diffstat (limited to 'Lib')
-rw-r--r-- | Lib/test/test_logging.py | 18 |
1 files changed, 9 insertions, 9 deletions
diff --git a/Lib/test/test_logging.py b/Lib/test/test_logging.py index 081ffe9..dc49fc1 100644 --- a/Lib/test/test_logging.py +++ b/Lib/test/test_logging.py @@ -81,7 +81,7 @@ class BaseTest(unittest.TestCase): """Base class for logging tests.""" log_format = "%(name)s -> %(levelname)s: %(message)s" - expected_log_pat = r"^([\w.]+) -> ([\w]+): ([\d]+)$" + expected_log_pat = r"^([\w.]+) -> (\w+): (\d+)$" message_num = 0 def setUp(self): @@ -438,7 +438,7 @@ class CustomLevelsAndFiltersTest(BaseTest): """Test various filtering possibilities with custom logging levels.""" # Skip the logger name group. - expected_log_pat = r"^[\w.]+ -> ([\w]+): ([\d]+)$" + expected_log_pat = r"^[\w.]+ -> (\w+): (\d+)$" def setUp(self): BaseTest.setUp(self) @@ -999,7 +999,7 @@ class MemoryHandlerTest(BaseTest): """Tests for the MemoryHandler.""" # Do not bother with a logger name group. - expected_log_pat = r"^[\w.]+ -> ([\w]+): ([\d]+)$" + expected_log_pat = r"^[\w.]+ -> (\w+): (\d+)$" def setUp(self): BaseTest.setUp(self) @@ -1052,7 +1052,7 @@ class ConfigFileTest(BaseTest): """Reading logging config from a .ini-style config file.""" - expected_log_pat = r"^([\w]+) \+\+ ([\w]+)$" + expected_log_pat = r"^(\w+) \+\+ (\w+)$" # config0 is a standard configuration. config0 = """ @@ -1795,7 +1795,7 @@ class ConfigDictTest(BaseTest): """Reading logging config from a dictionary.""" - expected_log_pat = r"^([\w]+) \+\+ ([\w]+)$" + expected_log_pat = r"^(\w+) \+\+ (\w+)$" # config0 is a standard configuration. config0 = { @@ -2691,7 +2691,7 @@ class ConfigDictTest(BaseTest): self.assert_log_lines([ ('INFO', '1'), ('ERROR', '2'), - ], pat=r"^[\w.]+ -> ([\w]+): ([\d]+)$") + ], pat=r"^[\w.]+ -> (\w+): (\d+)$") # Now, perform no verification. Our configuration # should take effect. @@ -2710,7 +2710,7 @@ class ConfigDictTest(BaseTest): self.assert_log_lines([ ('INFO', '1'), ('ERROR', '2'), - ], pat=r"^[\w.]+ -> ([\w]+): ([\d]+)$") + ], pat=r"^[\w.]+ -> (\w+): (\d+)$") # Now, perform verification which transforms the bytes. @@ -2728,7 +2728,7 @@ class ConfigDictTest(BaseTest): self.assert_log_lines([ ('INFO', '1'), ('ERROR', '2'), - ], pat=r"^[\w.]+ -> ([\w]+): ([\d]+)$") + ], pat=r"^[\w.]+ -> (\w+): (\d+)$") def test_baseconfig(self): d = { @@ -2832,7 +2832,7 @@ class LogRecordFactoryTest(BaseTest): class QueueHandlerTest(BaseTest): # Do not bother with a logger name group. - expected_log_pat = r"^[\w.]+ -> ([\w]+): ([\d]+)$" + expected_log_pat = r"^[\w.]+ -> (\w+): (\d+)$" def setUp(self): BaseTest.setUp(self) |