From a4f812c0e8874bddfa3b131bf4100608ed36a751 Mon Sep 17 00:00:00 2001 From: Aditya Narayan Date: Wed, 27 Sep 2023 09:52:39 +0530 Subject: [PATCH] change the variable name to standard --- src/LCT.PackageIdentifier.UTest/ConanParserTests.cs | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/src/LCT.PackageIdentifier.UTest/ConanParserTests.cs b/src/LCT.PackageIdentifier.UTest/ConanParserTests.cs index 9104925e..3607db2f 100644 --- a/src/LCT.PackageIdentifier.UTest/ConanParserTests.cs +++ b/src/LCT.PackageIdentifier.UTest/ConanParserTests.cs @@ -28,7 +28,7 @@ public class ConanParserTests public void ParseLockFile_GivenAInputFilePath_ReturnsSuccess() { //Arrange - int expectednoofcomponents = 17; + int expectedNoOfcomponents = 17; string exePath = System.Reflection.Assembly.GetExecutingAssembly().Location; string outFolder = Path.GetDirectoryName(exePath); string packagefilepath = outFolder + @"\PackageIdentifierUTTestFiles"; @@ -49,7 +49,7 @@ public void ParseLockFile_GivenAInputFilePath_ReturnsSuccess() Bom listofcomponents = new ConanProcessor().ParsePackageFile(appSettings); //Assert - Assert.That(expectednoofcomponents, Is.EqualTo(listofcomponents.Components.Count), "Checks for no of components"); + Assert.That(expectedNoOfcomponents, Is.EqualTo(listofcomponents.Components.Count), "Checks for no of components"); } @@ -76,8 +76,8 @@ public void ParseLockFile_GivenAInputFilePath_ReturnDevDependentComp() //Act Bom listofcomponents = new ConanProcessor().ParsePackageFile(appSettings); - - var IsDevDependency = listofcomponents.Components.Find(a => a.Name == "googletest").Properties[0].Value; + var IsDevDependency = listofcomponents.Components.Find(a => a.Name == "googletest") + .Properties.First(x => x.Name == "internal:siemens:clearing:development").Value; //Assert Assert.That(IsDev, Is.EqualTo(IsDevDependency), "Checks if Dev Dependency Component or not");