def assert_span(self, exporter=None, num_spans=1):
    if (exporter is None):
        exporter = self.memory_exporter
    span_list = exporter.get_finished_spans()
    self.assertEqual(num_spans, len(span_list))
    if (num_spans == 0):
        return None
    if (num_spans == 1):
        return span_list[0]
    return span_list
def assert_span(self, exporter=None, num_spans=1):
    if (exporter is None):
        exporter = self.memory_exporter
    span_list = exporter.get_finished_spans()
    self.assertEqual(num_spans, len(span_list))
    if (num_spans == 0):
        return None
    if (num_spans == 1):
        return span_list[0]
    return span_list