code: def test_error_in_rules(self) -> None:
      grammar_source = """
          start: expr+ NEWLINE? ENDMARKER
          expr: NAME {PyTuple_New(-1)}
          """
      # PyTuple_New raises SystemError if an invalid argument was passed.
      test_source = """
          with self.assertRaises(SystemError):
              parse.parse_string("a", mode=0)
          """
      self.run_test(grammar_source, test_source)
  
imports: import contextlib
  import subprocess
  import sysconfig
  import textwrap
  import unittest
  import os
  import shutil
  import tempfile
  from pathlib import Path
  from test import test_tools
  from test import support
  from test.support import os_helper, import_helper
  from test.support.script_helper import assert_python_ok
label_desc: Use image node_id 24 for calling the TestCParser obj's underlying member method code with example usage: obj.test_error_in_rules() without return types