code: def test_pretagged():
      """
      Test that the pipeline does or doesn't build if pos is left out and pretagged is specified
      """
      nlp = stanza.Pipeline(
          lang="en",
          dir=TEST_MODELS_DIR,
          processors="tokenize,pos,lemma,depparse",
      )
      with pytest.raises(core.PipelineRequirementsException):
          nlp = stanza.Pipeline(
              lang="en",
              dir=TEST_MODELS_DIR,
              processors="tokenize,lemma,depparse",
          )
      nlp = stanza.Pipeline(
          lang="en",
          dir=TEST_MODELS_DIR,
          processors="tokenize,lemma,depparse",
          depparse_pretagged=True,
      )
      nlp = stanza.Pipeline(
          lang="en",
          dir=TEST_MODELS_DIR,
          processors="tokenize,lemma,depparse",
          pretagged=True,
      )
      # test that the module specific flag overrides the general flag
      nlp = stanza.Pipeline(
          lang="en",
          dir=TEST_MODELS_DIR,
          processors="tokenize,lemma,depparse",
          depparse_pretagged=True,
          pretagged=False,
      )
  
imports: import pytest
  import shutil
  import tempfile
  import stanza
  from stanza.tests import *
  from stanza.pipeline import core
  from stanza.resources.common import get_md5, load_resources_json
label_desc: Use image node_id 1 for calling a global function with example usage: test_pretagged() without return types