code: def test_erase_screen(cls, capfd):
      with capfd.disabled():
          o = CapList()
          r = cls("stdout", cbs=[o.append])
          r.install()
          s = "QWERT\nYUIOP\n12345"
          s += "\r"
          s += "\x1b[J"
          s += "\x1b[A"
          s += "\r"
          s += "\x1b[1J"
          print(s)
          r.uninstall()
          assert o == [b" UIOP"]
          o = CapList()
          r = cls("stdout", cbs=[o.append])
          r.install()
          print("QWERT\nYUIOP\n12345")
          print("\x1b[2J")
          r.uninstall()
          assert o == []
  
imports: import os
  import re
  import sys
  import time
  import numpy
  import pytest
  import tqdm
  import wandb
label_desc: Use image node_id 6 for calling a global function with example usage: test_erase_screen(cls, capfd) without return types