def METHOD_NAME(self):
    emitter_provider_mock = Mock(spec=LoggerProvider)
    emitter_mock = APIGetLogger(
        __name__, logger_provider=emitter_provider_mock
    )
    logger = get_logger(logger_provider=emitter_provider_mock)
    tracer = trace.TracerProvider().get_tracer(__name__)
    with tracer.start_as_current_span("test") as span:
        with self.assertLogs(level=logging.CRITICAL):
            logger.critical("Critical message within span")
        args, _ = emitter_mock.emit.call_args_list[0]
        log_record = args[0]
        self.assertEqual(log_record.body, "Critical message within span")
        self.assertEqual(log_record.severity_text, "CRITICAL")
        self.assertEqual(log_record.severity_number, SeverityNumber.FATAL)
        span_context = span.get_span_context()
        self.assertEqual(log_record.trace_id, span_context.trace_id)
        self.assertEqual(log_record.span_id, span_context.span_id)
        self.assertEqual(log_record.trace_flags, span_context.trace_flags)