Update DetectionTemplateSchemaValidationTests.cs
This commit is contained in:
Родитель
3b24c07878
Коммит
8450d74a1b
|
@ -87,7 +87,7 @@ namespace Kqlvalidations.Tests
|
||||||
|
|
||||||
var templatesAsObjects = templatesAsStrings.Select(yaml => JObject.Parse(ConvertYamlToJson(yaml)));
|
var templatesAsObjects = templatesAsStrings.Select(yaml => JObject.Parse(ConvertYamlToJson(yaml)));
|
||||||
var duplicationsById = templatesAsObjects.GroupBy(a => a["id"]).Where(group => group.Count() > 1); //Finds duplications -> ids that there are more than 1 template from
|
var duplicationsById = templatesAsObjects.GroupBy(a => a["id"]).Where(group => group.Count() > 1); //Finds duplications -> ids that there are more than 1 template from
|
||||||
Assert.True(duplicationsById.Count() == 0);
|
Assert.True(duplicationsById.Count() == 0, "Found duplication of IDs. There should not be 2 templates with the same ID");
|
||||||
}
|
}
|
||||||
|
|
||||||
private string GetYamlFileAsString(string detectionsYamlFileName)
|
private string GetYamlFileAsString(string detectionsYamlFileName)
|
||||||
|
|
Загрузка…
Ссылка в новой задаче