code: def test_upgrade():
      slc = Slice(
          slice_name="FOO",
          query_context=json.dumps(sample_query_context),
      )
  
      upgrade_slice(slc)
  
      query_context = json.loads(slc.query_context)
      queries = query_context.get("queries")
      for q in queries:
          extras = q.get("extras", {})
          assert "time_range_endpoints" not in extras
  
      form_data = query_context.get("form_data", {})
      assert "time_range_endpoints" not in form_data
  
imports: import json
  from importlib import import_module
label_desc: Use image node_id 1 for calling a global function with example usage: test_upgrade() without return types