code: def test_put_one(s3root, objs, expected, s3_server_side_encryption):
      encryption_settings = [None, s3_server_side_encryption]
      for setting in encryption_settings:
          with S3(s3root=s3root, encryption=setting) as s3:
              for key, obj in objs:
                  s3url = s3.put(key, obj)
                  assert s3url in expected
                  s3obj = s3.get(key)
                  assert s3obj.key == key
                  assert_results(
                      [s3obj],
                      {s3url: expected[s3url]},
                      encryption=setting,
                  )
                  assert s3obj.blob == to_bytes(obj)
                  # put with overwrite disabled
                  s3url = s3.put(key, "random_value", overwrite=False)
                  assert s3url in expected
                  s3obj = s3.get(key)
                  assert s3obj.key == key
                  assert_results(
                      [s3obj],
                      {s3url: expected[s3url]},
                      encryption=setting,
                  )
                  assert s3obj.blob == to_bytes(obj)
  
imports: import os
  from re import I
  import shutil
  from hashlib import sha1
  from tempfile import mkdtemp
  from itertools import groupby, starmap
  import random
  from uuid import uuid4
  from metaflow.plugins.datatools import s3
  import pytest
  from metaflow import current, namespace, Run
  from metaflow.plugins.datatools.s3 import S3, MetaflowS3AccessDenied, MetaflowS3NotFound, MetaflowS3URLException, MetaflowS3InvalidObject, S3PutObject, S3GetObject
  from metaflow.util import to_bytes, unicode_type
  from .None import s3_data
  from ..None import FakeFlow, DO_TEST_RUN
label_desc: Use image node_id 27 for calling a global function with example usage: test_put_one(s3root, objs, expected, s3_server_side_encryption) without return types