code: def test_option_precedence_mark(pytester: Pytester) -> None:
      """Filters defined by marks should always take precedence (#3946)."""
      pytester.makeini(
          """
          [pytest]
          filterwarnings = ignore
      """
      )
      pytester.makepyfile(
          """
          import pytest, warnings
          @pytest.mark.filterwarnings('error')
          def test():
              warnings.warn(UserWarning('hello'))
      """
      )
      result = pytester.runpytest("-W", "ignore")
      result.stdout.fnmatch_lines(["* 1 failed in*"])
  
imports: import os
  import sys
  import warnings
  from typing import List
  from typing import Optional
  from typing import Tuple
  import pytest
  from _pytest.fixtures import FixtureRequest
  from _pytest.pytester import Pytester
label_desc: Use image node_id 16 for calling a global function with example usage: test_option_precedence_mark(pytester) without return types