code: def test_subscope_names(each_version):
      def get_sub(source):
          return parse(source, version=each_version).children[0]
  
      name = get_sub("class Foo: pass").name
      assert name.start_pos == (1, len("class "))
      assert name.end_pos == (1, len("class Foo"))
      assert name.value == "Foo"
  
      name = get_sub("def foo(): pass").name
      assert name.start_pos == (1, len("def "))
      assert name.end_pos == (1, len("def foo"))
      assert name.value == "foo"
  
imports: from textwrap import dedent
  import pytest
  from parso import parse
  from parso.python import tree
  from parso.utils import split_lines
label_desc: Use image node_id 2 for calling a global function with example usage: test_subscope_names(each_version) and returns: parse