def test_litellm_openai_azure(self):
        """Check that cost tracking works for openai models through litellm."""

        os.environ["OPENAI_API_TYPE"] = "azure"
        os.environ["AZURE_API_BASE"] = os.getenv(
            "AZURE_OPENAI_ENDPOINT"
        )  # this is required to be set explicitly for some weird reason alongside the api_base in completion_kwargs

        # Have to delete litellm endpoint singleton as it may have been created
        # with the wrong underlying litellm provider in a prior test.
        from trulens.providers.litellm.endpoint import LiteLLMEndpoint

        LiteLLMEndpoint.delete_instances()

        from trulens.providers.litellm import LiteLLM

        provider = LiteLLM(
            f"azure/{os.environ['AZURE_OPENAI_DEPLOYMENT']}",
        )

        self._test_llm_provider_endpoint(provider)
Check that cost tracking works for openai models through litellm.
tests/e2e/test_endpoints.py