Home
last modified time | relevance | path

Searched refs:assertRaisesSyntaxError (Results 1 – 3 of 3) sorted by relevance

/third_party/python/Lib/test/
Dtest_keywordonlyarg.py38 def assertRaisesSyntaxError(self, codestr): member in KeywordOnlyArgTestCase
44 self.assertRaisesSyntaxError("def f(p, *):\n pass\n")
45 self.assertRaisesSyntaxError("def f(p1, *, p1=100):\n pass\n")
46 self.assertRaisesSyntaxError("def f(p1, *k1, k1=100):\n pass\n")
47 self.assertRaisesSyntaxError("def f(p1, *, k1, k1=100):\n pass\n")
48 self.assertRaisesSyntaxError("def f(p1, *, **k1):\n pass\n")
49 self.assertRaisesSyntaxError("def f(p1, *, k1, **k1):\n pass\n")
50 self.assertRaisesSyntaxError("def f(p1, *, None, **k1):\n pass\n")
51 self.assertRaisesSyntaxError("def f(p, *, (k1, k2), **kw):\n pass\n")
71 self.assertRaisesSyntaxError("f(p, k=1, p2)")
[all …]
Dtest_with.py141 def assertRaisesSyntaxError(self, codestr): member in FailureTestCase
147 self.assertRaisesSyntaxError('with mock as None:\n pass')
148 self.assertRaisesSyntaxError(
153 self.assertRaisesSyntaxError('with mock as None,:\n pass')
154 self.assertRaisesSyntaxError(
159 self.assertRaisesSyntaxError(
Dtest_positional_only_arg.py21 def assertRaisesSyntaxError(self, codestr, regex="invalid syntax"): member in PositionalOnlyTestCase