

@classmethod
def setUpClass(cls):
    super(TestSample, cls).setUpClass()
    cls.meter = next(cls.conn.telemetry.meters())
    resource = next(cls.conn.telemetry.resources())
    sot = cls.conn.telemetry.create_sample(counter_name=cls.meter.name, meter=cls.meter.name, counter_type='gauge', counter_unit='instance', counter_volume=1.0, resource_id=resource.id)
    assert isinstance(sot, sample.Sample)
    cls.sample = sot

dataset/ETHPy150Open openstack/python-openstacksdk/openstack/tests/functional/telemetry/v2/test_sample.py TestSample.setUpClass/original