code: def test_setting_non_empty_value(self):
      # Simulate user setting a value for the upload from the kernel.
      uploader = FileUpload()
      content = memoryview(b"some content")
      uploader.value = [
          {
              "name": "some-name.txt",
              "type": "text/plain",
              "size": 561,
              "last_modified": dt.datetime(
                  2020, 1, 9, 13, 58, 16, 434000, tzinfo=dt.timezone.utc
              ),
              "content": content,
          }
      ]
      state = uploader.get_state(key="value")
      assert len(state["value"]) == 1
      [entry] = state["value"]
      assert entry["name"] == "some-name.txt"
      assert entry["type"] == "text/plain"
      assert entry["size"] == 561
      assert entry["last_modified"] == 1578578296434
      assert entry["content"] == content
  
file_path: catboost/contrib/python/ipywidgets/py3/ipywidgets/widgets/tests/test_widget_upload.py
imports: import datetime
  from unittest import TestCase
  from unittest.mock import MagicMock
  from traitlets import TraitError
  from ipywidgets import FileUpload
label_desc: Use image node_id 8 for calling the TestFileUpload obj's underlying member method code with example usage: obj.test_setting_non_empty_value() without return types