docstr: We should get a unique UploadedFile instance each time we access
  the file_uploader widget.
docstr_tok: ["We","should","get","a","unique","UploadedFile","instance","each","time","we","access","the","file_uploader","widget","."]
code: def test_unique_uploaded_file_instance(self, get_upload_files_patch):
      """We should get a unique UploadedFile instance each time we access
      the file_uploader widget."""
  
      # Patch UploadFileManager to return two files
      rec1 = UploadedFileRec("file1", "file1", "type", b"123")
      rec2 = UploadedFileRec("file2", "file2", "type", b"456")
  
      uploaded_files = [
          UploadedFile(
              rec1,
              FileURLsProto(
                  file_id="file1", delete_url="d1", upload_url="u1"
              ),
          ),
          UploadedFile(
              rec2,
              FileURLsProto(
                  file_id="file2", delete_url="d1", upload_url="u1"
              ),
          ),
      ]
  
      get_upload_files_patch.return_value = uploaded_files
  
      # These file_uploaders have different labels so that we don't cause
      # a DuplicateKey error - but because we're patching the get_files
      # function, both file_uploaders will refer to the same files.
      file1: UploadedFile = st.file_uploader(
          "a", accept_multiple_files=False
      )
      file2: UploadedFile = st.file_uploader(
          "b", accept_multiple_files=False
      )
  
      self.assertNotEqual(id(file1), id(file2))
  
      # Seeking in one instance should not impact the position in the other.
      file1.seek(2)
      self.assertEqual(b"3", file1.read())
      self.assertEqual(b"123", file2.read())
  
imports: from unittest.mock import patch
  from parameterized import parameterized
  import streamlit
  from streamlit import config
  from streamlit.errors import StreamlitAPIException
  from streamlit.proto.Common_pb2 import FileURLs
  from streamlit.proto.LabelVisibilityMessage_pb2 import LabelVisibilityMessage
  from streamlit.runtime.uploaded_file_manager import DeletedFile, UploadedFile, UploadedFileRec
  from tests.delta_generator_test_case import DeltaGeneratorTestCase
label_desc: Use image node_id 9 for calling the FileUploaderTest obj's underlying member method code with example usage: obj.test_unique_uploaded_file_instance(get_upload_files_patch) without return types