code: def test_cors(self):
      w = IntText(4)
      code = embed_snippet(w)
      # 1 is from the require
      assert len(re.findall(" crossorigin", code)) > 1
      f = StringIO()
      embed_minimal_html(f, w)
      assert len(re.findall(" crossorigin", f.getvalue())) > 1
  
      code = embed_snippet(w, cors=False, requirejs=False)
      assert " crossorigin" not in code
      f = StringIO()
      embed_minimal_html(f, w, cors=False, requirejs=False)
      assert " crossorigin" not in f.getvalue()
  
      code = embed_snippet(w, cors=False, requirejs=True)
      assert (
          len(re.findall(" crossorigin", code)) == 1
      )  # 1 is from the require, which is ok
      f = StringIO()
      embed_minimal_html(f, w, cors=False, requirejs=True)
      assert len(re.findall(" crossorigin", f.getvalue())) == 1
  
imports: from io import StringIO
  from html.parser import HTMLParser
  import json
  import os
  import re
  import tempfile
  import shutil
  import traitlets
  from ipywidgets.widgets import IntSlider, IntText, Text, Widget, jslink, HBox, widget_serialization, widget
  from ipywidgets.embed import embed_data, embed_snippet, embed_minimal_html, dependency_state
label_desc: Use image node_id 3 for calling the TestEmbed obj's underlying member method code with example usage: obj.test_cors() without return types