code: def test_vertex_to_object_context(sagemaker_session):
      vertex = Vertex(
          arn="arn:aws:sagemaker:us-west-2:0123456789012:context/mycontext",
          lineage_entity=LineageEntityEnum.CONTEXT.value,
          lineage_source=LineageSourceEnum.MODEL_DEPLOYMENT.value,
          sagemaker_session=sagemaker_session,
      )
  
      sagemaker_session.sagemaker_client.describe_context.return_value = {
          "ContextName": "MyContext",
          "ContextArn": "arn:aws:sagemaker:us-west-2:0123456789012:context/mycontext",
          "Source": {
              "SourceUri": "arn:aws:sagemaker:us-west-2:0123456789012:model/mymodel",
              "SourceType": "ARN",
              "SourceId": "Thu Dec 17 17:16:24 UTC 2020",
          },
          "ContextType": "ModelDeployment",
          "Properties": {
              "PipelineExecutionArn": "arn:aws:sagemaker:us-west-2:0123456789012:\
                  pipeline/mypipeline/execution/0irnteql64d0",
              "PipelineStepName": "MyStep",
              "Status": "Completed",
          },
          "CreationTime": 1608225384.0,
          "CreatedBy": {},
          "LastModifiedTime": 1608225384.0,
          "LastModifiedBy": {},
      }
  
      context = vertex.to_lineage_object()
  
      assert (
          context.context_arn
          == "arn:aws:sagemaker:us-west-2:0123456789012:context/mycontext"
      )
      assert context.context_name == "MyContext"
      assert isinstance(context, Context)
  
imports: from __future__ import absolute_import
  import unittest.mock
  from sagemaker.lineage.artifact import DatasetArtifact, ModelArtifact, Artifact
  from sagemaker.lineage.context import EndpointContext, Context
  from sagemaker.lineage.action import Action
  from sagemaker.lineage.lineage_trial_component import LineageTrialComponent
  from sagemaker.lineage.query import LineageEntityEnum, LineageSourceEnum, Vertex, LineageQuery
  import pytest
  import re
label_desc: Use image node_id 6 for calling a global function with example usage: test_vertex_to_object_context(sagemaker_session) without return types