Пример #1
0
        public void MetricWireModelTests_MetricBuilder_SupportabilityDistributedTracing(string propertyName, string name)
        {
            var propertyInfo = _metricBuilder.GetType().GetProperty(propertyName);

            Assert.That(propertyInfo, Is.Not.Null);

            var obj = propertyInfo.GetValue(_metricBuilder);

            Assert.That(obj, Is.Not.Null);
            Assert.That(obj, Is.InstanceOf(typeof(MetricWireModel)));

            var wireModel = obj as MetricWireModel;

            Assert.That(wireModel, Is.Not.Null);

            Assert.That(wireModel.MetricName.Name, Is.EqualTo(name));
            Assert.That(wireModel.Data.Value0, Is.EqualTo(1));
            Assert.That(wireModel.Data.Value1, Is.EqualTo(0));
            Assert.That(wireModel.Data.Value2, Is.EqualTo(0));
            Assert.That(wireModel.Data.Value3, Is.EqualTo(0));
            Assert.That(wireModel.Data.Value4, Is.EqualTo(0));
            Assert.That(wireModel.Data.Value5, Is.EqualTo(0));
        }