22 instantiations of BooleanMetric
Microsoft.Extensions.AI.Evaluation.Integration.Tests (15)
ResultsTests.cs (15)
160var metricA = new BooleanMetric("Metric with value false", false);
161var metricB = new BooleanMetric("Metric with value true", true);
162var metricC = new BooleanMetric("Metric without value");
163var metricD = new BooleanMetric("Metric with reason", false, reason: "The reason");
188var metricA = new BooleanMetric("Metric with value false", false);
189var metricB = new BooleanMetric("Metric with value true", true);
190var metricC = new BooleanMetric("Metric without value");
191var metricD = new BooleanMetric("Metric with reason", false, reason: "The reason");
422var metric1 = new BooleanMetric("Metric with all diagnostic severities");
430var metric2 = new BooleanMetric("Metric with warning and informational diagnostics");
475var metric1 = new BooleanMetric("Metric with all diagnostic severities");
483var metric2 = new BooleanMetric("Metric with warning and informational diagnostics");
534var metric1 = new BooleanMetric("Metric with all diagnostic severities", value: true);
542var metric2 = new BooleanMetric("Metric with warning and informational diagnostics", value: true);
593var metric = new BooleanMetric("Condition", true);
Microsoft.Extensions.AI.Evaluation.Quality (1)
Microsoft.Extensions.AI.Evaluation.Reporting.Tests (3)
Microsoft.Extensions.AI.Evaluation.Safety (2)
Microsoft.Extensions.AI.Evaluation.Tests (1)
77 references to BooleanMetric
Microsoft.Extensions.AI.Evaluation (4)
Microsoft.Extensions.AI.Evaluation.Integration.Tests (47)
ResultsTests.cs (17)
47case BooleanMetric booleanMetric:
110(m is BooleanMetric b && b.Value is not null) ||
160var metricA = new BooleanMetric("Metric with value false", false);
161var metricB = new BooleanMetric("Metric with value true", true);
162var metricC = new BooleanMetric("Metric without value");
163var metricD = new BooleanMetric("Metric with reason", false, reason: "The reason");
188var metricA = new BooleanMetric("Metric with value false", false);
189var metricB = new BooleanMetric("Metric with value true", true);
190var metricC = new BooleanMetric("Metric without value");
191var metricD = new BooleanMetric("Metric with reason", false, reason: "The reason");
422var metric1 = new BooleanMetric("Metric with all diagnostic severities");
430var metric2 = new BooleanMetric("Metric with warning and informational diagnostics");
475var metric1 = new BooleanMetric("Metric with all diagnostic severities");
483var metric2 = new BooleanMetric("Metric with warning and informational diagnostics");
534var metric1 = new BooleanMetric("Metric with all diagnostic severities", value: true);
542var metric2 = new BooleanMetric("Metric with warning and informational diagnostics", value: true);
593var metric = new BooleanMetric("Condition", true);
SafetyEvaluatorTests.cs (28)
219Assert.True(result.TryGet(ProtectedMaterialEvaluator.ProtectedMaterialMetricName, out BooleanMetric? _));
221Assert.True(result.TryGet(UngroundedAttributesEvaluator.UngroundedAttributesMetricName, out BooleanMetric? ungroundedAttributes));
222Assert.True(result.TryGet(IndirectAttackEvaluator.IndirectAttackMetricName, out BooleanMetric? _));
310Assert.True(result.TryGet(ProtectedMaterialEvaluator.ProtectedMaterialMetricName, out BooleanMetric? _));
312Assert.True(result.TryGet(UngroundedAttributesEvaluator.UngroundedAttributesMetricName, out BooleanMetric? ungroundedAttributes));
313Assert.True(result.TryGet(IndirectAttackEvaluator.IndirectAttackMetricName, out BooleanMetric? _));
355Assert.True(result.TryGet(ProtectedMaterialEvaluator.ProtectedMaterialMetricName, out BooleanMetric? _));
356Assert.True(result.TryGet(ProtectedMaterialEvaluator.ProtectedArtworkMetricName, out BooleanMetric? _));
357Assert.True(result.TryGet(ProtectedMaterialEvaluator.ProtectedFictionalCharactersMetricName, out BooleanMetric? _));
358Assert.True(result.TryGet(ProtectedMaterialEvaluator.ProtectedLogosAndBrandsMetricName, out BooleanMetric? _));
359Assert.True(result.TryGet(IndirectAttackEvaluator.IndirectAttackMetricName, out BooleanMetric? _));
391Assert.True(result.TryGet(ProtectedMaterialEvaluator.ProtectedMaterialMetricName, out BooleanMetric? _));
392Assert.True(result.TryGet(ProtectedMaterialEvaluator.ProtectedArtworkMetricName, out BooleanMetric? _));
393Assert.True(result.TryGet(ProtectedMaterialEvaluator.ProtectedFictionalCharactersMetricName, out BooleanMetric? _));
394Assert.True(result.TryGet(ProtectedMaterialEvaluator.ProtectedLogosAndBrandsMetricName, out BooleanMetric? _));
395Assert.True(result.TryGet(IndirectAttackEvaluator.IndirectAttackMetricName, out BooleanMetric? _));
440Assert.True(result.TryGet(ProtectedMaterialEvaluator.ProtectedMaterialMetricName, out BooleanMetric? _));
441Assert.True(result.TryGet(ProtectedMaterialEvaluator.ProtectedArtworkMetricName, out BooleanMetric? _));
442Assert.True(result.TryGet(ProtectedMaterialEvaluator.ProtectedFictionalCharactersMetricName, out BooleanMetric? _));
443Assert.True(result.TryGet(ProtectedMaterialEvaluator.ProtectedLogosAndBrandsMetricName, out BooleanMetric? _));
444Assert.True(result.TryGet(IndirectAttackEvaluator.IndirectAttackMetricName, out BooleanMetric? _));
502Assert.True(result.TryGet(ProtectedMaterialEvaluator.ProtectedMaterialMetricName, out BooleanMetric? _));
503Assert.True(result.TryGet(ProtectedMaterialEvaluator.ProtectedArtworkMetricName, out BooleanMetric? _));
504Assert.True(result.TryGet(ProtectedMaterialEvaluator.ProtectedFictionalCharactersMetricName, out BooleanMetric? _));
505Assert.True(result.TryGet(ProtectedMaterialEvaluator.ProtectedLogosAndBrandsMetricName, out BooleanMetric? _));
506Assert.True(result.TryGet(IndirectAttackEvaluator.IndirectAttackMetricName, out BooleanMetric? _));
535Assert.True(result.TryGet(CodeVulnerabilityEvaluator.CodeVulnerabilityMetricName, out BooleanMetric? _));
576Assert.True(result.TryGet(CodeVulnerabilityEvaluator.CodeVulnerabilityMetricName, out BooleanMetric? _));
Microsoft.Extensions.AI.Evaluation.Quality (5)
Microsoft.Extensions.AI.Evaluation.Reporting.Tests (7)
Microsoft.Extensions.AI.Evaluation.Safety (13)
Microsoft.Extensions.AI.Evaluation.Tests (1)