code: def check_russian_doc(doc):
      """
      Refactored the test for the Russian doc so we can use it to test various file methods
      """
      lines = RUSSIAN_SAMPLE.split("\n")
      assert len(doc.sentences) == 2
      assert lines[0] == doc.sentences[0].comments[0]
      assert lines[1] == doc.sentences[0].comments[1]
      assert lines[2] == doc.sentences[0].comments[2]
      for sent_idx, (expected_text, expected_id, sentence) in enumerate(
          zip(RUSSIAN_TEXT, RUSSIAN_IDS, doc.sentences)
      ):
          assert expected_text == sentence.text
          assert expected_id == sentence.sent_id
          assert sent_idx == sentence.index
          assert len(sentence.comments) == 3
          assert not sentence.has_enhanced_dependencies()
  
      sentences = "{:C}".format(doc)
      sentences = sentences.split("\n\n")
      assert len(sentences) == 2
  
      sentence = sentences[0].split("\n")
      assert len(sentence) == 14
      assert lines[0] == sentence[0]
      assert lines[1] == sentence[1]
      assert lines[2] == sentence[2]
  
      # assert that the weird deprel=list:goeswith was properly handled
      assert doc.sentences[0].words[2].head == 1
      assert doc.sentences[0].words[2].deprel == "list:goeswith"
  
imports: import io
  import pytest
  import tempfile
  from zipfile import ZipFile
  import stanza
  from stanza.utils.conll import CoNLL
  from stanza.models.common.doc import Document
  from stanza.tests import *
label_desc: Use image node_id 4 for calling a global function with example usage: check_russian_doc(doc) without return types