code: def test_python_tee_output(capsys):
      expected_lines = {"captured stdout", "captured stderr"}
  
      capture_mode, capture_stdout = get_stdcapturer("sys")
      with capsys.disabled():
          print("before (stdout)")
          print("before (stderr)")
          with capture_stdout() as out:
              print("captured stdout")
              print("captured stderr")
          output = out.get()
  
          print("after (stdout)")
          print("after (stderr)")
  
          assert set(output.strip().split("\n")) == expected_lines
  
imports: import os
  import sys
  import pytest
  from sacred.stdout_capturing import get_stdcapturer
  from sacred.optional import libc
label_desc: Use image node_id 1 for calling a global function with example usage: test_python_tee_output(capsys) without return types