(self)
| 1962 | self.checkPatternError(r'(?iz', 'unknown flag', 3) |
| 1963 | |
| 1964 | def test_ignore_spaces(self): |
| 1965 | for space in " \t\n\r\v\f": |
| 1966 | self.assertTrue(re.fullmatch(space + 'a', 'a', re.VERBOSE)) |
| 1967 | for space in b" ", b"\t", b"\n", b"\r", b"\v", b"\f": |
| 1968 | self.assertTrue(re.fullmatch(space + b'a', b'a', re.VERBOSE)) |
| 1969 | self.assertTrue(re.fullmatch('(?x) a', 'a')) |
| 1970 | self.assertTrue(re.fullmatch(' (?x) a', 'a', re.VERBOSE)) |
| 1971 | self.assertTrue(re.fullmatch('(?x) (?x) a', 'a')) |
| 1972 | self.assertTrue(re.fullmatch(' a(?x: b) c', ' ab c')) |
| 1973 | self.assertTrue(re.fullmatch(' a(?-x: b) c', 'a bc', re.VERBOSE)) |
| 1974 | self.assertTrue(re.fullmatch('(?x) a(?-x: b) c', 'a bc')) |
| 1975 | self.assertTrue(re.fullmatch('(?x) a| b', 'a')) |
| 1976 | self.assertTrue(re.fullmatch('(?x) a| b', 'b')) |
| 1977 | |
| 1978 | def test_comments(self): |
| 1979 | self.assertTrue(re.fullmatch('#x\na', 'a', re.VERBOSE)) |
nothing calls this directly
no test coverage detected