diff --git a/.github/workflows/compile.yml b/.github/workflows/compile.yml index 59c7cd52..9992b972 100644 --- a/.github/workflows/compile.yml +++ b/.github/workflows/compile.yml @@ -7,8 +7,8 @@ on: - cron: "30 0 * * 5" jobs: + build: - runs-on: self-hosted defaults: diff --git a/src/LCT.PackageIdentifier.UTest/MavenParserTests.cs b/src/LCT.PackageIdentifier.UTest/MavenParserTests.cs index e531690c..fd05faeb 100644 --- a/src/LCT.PackageIdentifier.UTest/MavenParserTests.cs +++ b/src/LCT.PackageIdentifier.UTest/MavenParserTests.cs @@ -87,14 +87,14 @@ public async Task IdentificationOfInternalComponents_ReturnsComponentData_Succes component1.Version = "1.0.0"; var components = new List() { component1 }; ComponentIdentification component = new() { comparisonBOMData = components }; - string[] reooListArr = { "energy-dev-npm-egll", "energy-release-npm-egll" }; + string[] reooListArr = { "internalrepo1", "internalrepo2" }; CommonAppSettings appSettings = new() { InternalRepoList = reooListArr }; AqlResult aqlResult = new() { Name = "animations-1.0.0.tgz", - Path = "@siemens-gds/saap-api-node/-/@siemens-gds", - Repo = "energy-dev-npm-egll" + Path = "@testfolder/-/folder", + Repo = "internalrepo1" }; List results = new List() { aqlResult }; @@ -123,14 +123,14 @@ public async Task IdentificationOfInternalComponents_ReturnsComponentData2_Succe component1.Version = "1.0.0"; var components = new List() { component1 }; ComponentIdentification component = new() { comparisonBOMData = components }; - string[] reooListArr = { "energy-dev-npm-egll", "energy-release-npm-egll" }; + string[] reooListArr = { "internalrepo1", "internalrepo2" }; CommonAppSettings appSettings = new() { InternalRepoList = reooListArr }; AqlResult aqlResult = new() { Name = "animations-common_license-1.0.0.tgz", - Path = "@siemens-gds/saap-api-node/-/@siemens-gds", - Repo = "energy-dev-npm-egll" + Path = "@testfolder/-/folder", + Repo = "internalrepo1" }; List results = new List() { aqlResult }; @@ -161,14 +161,14 @@ public async Task IdentificationOfInternalComponents_ReturnsComponentData3_Succe }; var components = new List() { component1 }; ComponentIdentification componentIdentification = new() { comparisonBOMData = components }; - string[] reooListArr = { "energy-dev-npm-egll", "energy-release-npm-egll" }; + string[] reooListArr = {"internalrepo1", "internalrepo2" }; CommonAppSettings appSettings = new() { InternalRepoList = reooListArr }; AqlResult aqlResult = new() { Name = "animations-common-1.0.0.tgz", - Path = "@siemens-gds/saap-api-node/-/@siemens-gds", - Repo = "energy-dev-npm-egll" + Path = "@testfolder/-/folder", + Repo = "internalrepo1" }; List results = new List() { aqlResult }; @@ -199,14 +199,14 @@ public async Task GetJfrogRepoDetailsOfAComponent_ReturnsWithData_SuccessFully() Version = "1.0.0" }; var components = new List() { component1 }; - string[] reooListArr = { "siparty-release-npm-egll", "org1-npmjs-npm-remote-cache" }; + string[] reooListArr = { "internalrepo1", "internalrepo2" }; CommonAppSettings appSettings = new(); appSettings.Maven = new Common.Model.Config() { JfrogMavenRepoList = reooListArr }; AqlResult aqlResult = new() { Name = "animations-common-1.0.0.tgz", - Path = "@siemens-gds/saap-api-node/-/@siemens-gds", - Repo = "siparty-release-npm-egll" + Path = "@testfolder/-/folder", + Repo = "internalrepo1" }; List results = new List() { aqlResult }; @@ -238,14 +238,14 @@ public async Task GetJfrogRepoDetailsOfAComponent_ReturnsWithData2_SuccessFully( Version = "1.0.0" }; var components = new List() { component1 }; - string[] reooListArr = { "siparty-release-npm-egll", "org1-npmjs-npm-remote-cache" }; + string[] reooListArr = { "internalrepo1", "internalrepo2" }; CommonAppSettings appSettings = new(); appSettings.Maven = new Common.Model.Config() { JfrogMavenRepoList = reooListArr }; AqlResult aqlResult = new() { Name = "animations-common-1.0.0.tgz", - Path = "@siemens-gds/saap-api-node/-/@siemens-gds", - Repo = "siparty-release-npm-egll" + Path = "@testfolder/-/folder", + Repo = "internalrepo1" }; List results = new List() { aqlResult }; diff --git a/src/LCT.PackageIdentifier.UTest/NpmProcessorUTest.cs b/src/LCT.PackageIdentifier.UTest/NpmProcessorUTest.cs index abee7c62..3d8466e1 100644 --- a/src/LCT.PackageIdentifier.UTest/NpmProcessorUTest.cs +++ b/src/LCT.PackageIdentifier.UTest/NpmProcessorUTest.cs @@ -31,14 +31,14 @@ public async Task IdentificationOfInternalComponents_ReturnsComponentData_Succes component1.Version = "1.0.0"; var components = new List() { component1 }; ComponentIdentification component = new() { comparisonBOMData = components }; - string[] reooListArr = { "energy-dev-npm-egll", "energy-release-npm-egll" }; + string[] reooListArr = { "internalrepo1", "internalrepo2" }; CommonAppSettings appSettings = new() { InternalRepoList = reooListArr }; AqlResult aqlResult = new() { Name = "animations-1.0.0.tgz", - Path = "@siemens-gds/saap-api-node/-/@siemens-gds", - Repo = "energy-dev-npm-egll" + Path = "@testfolder/-/folder", + Repo = "internalrepo1" }; List results = new List() { aqlResult }; @@ -67,14 +67,14 @@ public async Task IdentificationOfInternalComponents_ReturnsComponentData2_Succe component1.Version = "1.0.0"; var components = new List() { component1 }; ComponentIdentification component = new() { comparisonBOMData = components }; - string[] reooListArr = { "energy-dev-npm-egll", "energy-release-npm-egll" }; + string[] reooListArr = { "internalrepo1", "internalrepo2" }; CommonAppSettings appSettings = new() { InternalRepoList = reooListArr }; AqlResult aqlResult = new() { Name = "animations-common_license-1.0.0.tgz", - Path = "@siemens-gds/saap-api-node/-/@siemens-gds", - Repo = "energy-dev-npm-egll" + Path = "@testfolder/-/folder", + Repo = "internalrepo1" }; List results = new List() { aqlResult }; @@ -105,14 +105,14 @@ public async Task IdentificationOfInternalComponents_ReturnsComponentData3_Succe }; var components = new List() { component1 }; ComponentIdentification componentIdentification = new() { comparisonBOMData = components }; - string[] reooListArr = { "energy-dev-npm-egll", "energy-release-npm-egll" }; + string[] reooListArr = { "internalrepo1", "internalrepo1" }; CommonAppSettings appSettings = new() { InternalRepoList = reooListArr }; AqlResult aqlResult = new() { Name = "animations-common-1.0.0.tgz", - Path = "@siemens-gds/saap-api-node/-/@siemens-gds", - Repo = "energy-dev-npm-egll" + Path = "@testfolder/-/folder", + Repo = "internalrepo1" }; List results = new List() { aqlResult }; @@ -143,14 +143,14 @@ public async Task GetJfrogRepoDetailsOfAComponent_ReturnsWithData_SuccessFully() Version = "1.0.0" }; var components = new List() { component1 }; - string[] reooListArr = { "siparty-release-npm-egll", "org1-npmjs-npm-remote-cache" }; + string[] reooListArr = { "internalrepo1", "internalrepo1" }; CommonAppSettings appSettings = new(); appSettings.Npm = new Common.Model.Config() { JfrogNpmRepoList = reooListArr }; AqlResult aqlResult = new() { Name = "animations-common-1.0.0.tgz", - Path = "@siemens-gds/saap-api-node/-/@siemens-gds", - Repo = "siparty-release-npm-egll" + Path = "@testfolder/-/folder", + Repo = "internalrepo1" }; List results = new List() { aqlResult }; @@ -182,14 +182,14 @@ public async Task GetJfrogRepoDetailsOfAComponent_ReturnsWithData2_SuccessFully( Version = "1.0.0" }; var components = new List() { component1 }; - string[] reooListArr = { "siparty-release-npm-egll", "org1-npmjs-npm-remote-cache" }; + string[] reooListArr = { "internalrepo1", "internalrepo2" }; CommonAppSettings appSettings = new(); appSettings.Npm = new Common.Model.Config() { JfrogNpmRepoList = reooListArr }; AqlResult aqlResult = new() { Name = "animations-common-1.0.0.tgz", - Path = "@siemens-gds/saap-api-node/-/@siemens-gds", - Repo = "siparty-release-npm-egll" + Path = "@testfolder/-/folder", + Repo = "internalrepo1" }; List results = new List() { aqlResult }; diff --git a/src/LCT.PackageIdentifier.UTest/NugetParserTests.cs b/src/LCT.PackageIdentifier.UTest/NugetParserTests.cs index 97de4054..228af2b7 100644 --- a/src/LCT.PackageIdentifier.UTest/NugetParserTests.cs +++ b/src/LCT.PackageIdentifier.UTest/NugetParserTests.cs @@ -230,14 +230,14 @@ public async Task IdentificationOfInternalComponents_Nuget_ReturnsComponentData_ component1.Version = "1.0.0"; var components = new List() { component1 }; ComponentIdentification component = new() { comparisonBOMData = components }; - string[] reooListArr = { "energy-dev-npm-egll", "energy-release-npm-egll" }; + string[] reooListArr = { "internalrepo1", "internalrepo1" }; CommonAppSettings appSettings = new() { InternalRepoList = reooListArr }; AqlResult aqlResult = new() { Name = "animations-1.0.0.nupkg", - Path = "@siemens-gds/saap-api-node/-/@siemens-gds", - Repo = "energy-dev-npm-egll" + Path = "@testfolder/-/folder", + Repo = "internalrepo1" }; List results = new List() { aqlResult }; @@ -267,14 +267,14 @@ public async Task IdentificationOfInternalComponents_Nuget_ReturnsComponentData2 component1.Version = "1.0.0"; var components = new List() { component1 }; ComponentIdentification component = new() { comparisonBOMData = components }; - string[] reooListArr = { "energy-dev-npm-egll", "energy-release-npm-egll" }; + string[] reooListArr = { "internalrepo1", "internalrepo2" }; CommonAppSettings appSettings = new() { InternalRepoList = reooListArr }; AqlResult aqlResult = new() { Name = "animations-common_license-1.0.0.nupkg", - Path = "@siemens-gds/saap-api-node/-/@siemens-gds", - Repo = "energy-dev-npm-egll" + Path = "@testfolder/-/folder", + Repo = "internalrepo1" }; List results = new List() { aqlResult }; @@ -305,14 +305,14 @@ public async Task IdentificationOfInternalComponents_ReturnsComponentData3_Succe }; var components = new List() { component1 }; ComponentIdentification componentIdentification = new() { comparisonBOMData = components }; - string[] reooListArr = { "energy-dev-npm-egll", "energy-release-npm-egll" }; + string[] reooListArr = { "internalrepo1", "internalrepo2" }; CommonAppSettings appSettings = new() { InternalRepoList = reooListArr }; AqlResult aqlResult = new() { Name = "animations-common-1.0.0.nupkg", - Path = "@siemens-gds/saap-api-node/-/@siemens-gds", - Repo = "energy-dev-npm-egll" + Path = "@testfolder/-/folder", + Repo = "internalrepo1" }; List results = new List() { aqlResult }; @@ -343,14 +343,14 @@ public async Task GetJfrogRepoDetailsOfAComponent_ReturnsWithData_SuccessFully() Version = "1.0.0" }; var components = new List() { component1 }; - string[] reooListArr = { "siparty-release-npm-egll", "org1-npmjs-npm-remote-cache" }; + string[] reooListArr = { "internalrepo1", "internalrepo2" }; CommonAppSettings appSettings = new(); appSettings.Nuget = new LCT.Common.Model.Config() { JfrogNugetRepoList = reooListArr }; AqlResult aqlResult = new() { Name = "animations-common-1.0.0.nupkg", - Path = "@siemens-gds/saap-api-node/-/@siemens-gds", - Repo = "siparty-release-npm-egll" + Path = "@testfolder/-/folder", + Repo = "internalrepo1" }; List results = new List() { aqlResult }; @@ -382,14 +382,14 @@ public async Task GetJfrogRepoDetailsOfAComponent_Nuget_ReturnsWithData2_Success Version = "1.0.0" }; var components = new List() { component1 }; - string[] reooListArr = { "siparty-release-npm-egll", "org1-npmjs-npm-remote-cache" }; + string[] reooListArr = {"internalrepo1", "internalrepo2" }; CommonAppSettings appSettings = new(); appSettings.Nuget = new Config() { JfrogNugetRepoList = reooListArr }; AqlResult aqlResult = new() { Name = "animations-common-1.0.0.nupkg", - Path = "@siemens-gds/saap-api-node/-/@siemens-gds", - Repo = "siparty-release-npm-egll" + Path = "@testfolder/-/folder", + Repo = "internalrepo1" }; List results = new List() { aqlResult }; @@ -421,14 +421,14 @@ public async Task GetArtifactoryRepoName_Nuget_ReturnsRepoName_SuccessFully() Version = "1.0.0" }; var components = new List() { component1 }; - string[] reooListArr = { "siparty-release-npm-egll", "org1-npmjs-npm-remote-cache" }; + string[] reooListArr = {"internalrepo1", "internalrepo2" }; CommonAppSettings appSettings = new(); appSettings.Nuget = new Config() { JfrogNugetRepoList = reooListArr }; AqlResult aqlResult = new() { Name = "animations-common-1.0.0.nupkg", - Path = "@siemens-gds/saap-api-node/-/@siemens-gds", - Repo = "siparty-release-npm-egll" + Path = "@testfolder/-/folder", + Repo = "internalrepo1" }; List results = new List() { aqlResult }; @@ -460,14 +460,14 @@ public async Task GetArtifactoryRepoName_Nuget_ReturnsRepoName_ReturnsFailure() Version = "1.0.0" }; var components = new List() { component1 }; - string[] reooListArr = { "siparty-release-npm-egll", "org1-npmjs-npm-remote-cache" }; + string[] reooListArr = {"internalrepo1", "internalrepo2" }; CommonAppSettings appSettings = new(); appSettings.Nuget = new Config() { JfrogNugetRepoList = reooListArr }; AqlResult aqlResult = new() { Name = "animation-test-1.0.0.nupkg", - Path = "@siemens-gds/saap-api-node/-/@siemens-gds", - Repo = "siparty-release-npm-egll" + Path = "@testfolder/-/folder", + Repo = "internalrepo1" }; List results = new () { aqlResult }; @@ -499,14 +499,14 @@ public async Task GetArtifactoryRepoName_Nuget_ReturnsRepoName_ReturnsSuccess() Version = "1.0.0" }; var components = new List() { component1 }; - string[] reooListArr = { "siparty-release-npm-egll", "org1-npmjs-npm-remote-cache" }; + string[] reooListArr = {"internalrepo1", "internalrepo2" }; CommonAppSettings appSettings = new(); appSettings.Nuget = new Config() { JfrogNugetRepoList = reooListArr }; AqlResult aqlResult = new() { Name = "animations-common.1.0.0.nupkg", - Path = "@siemens-gds/saap-api-node/-/@siemens-gds", - Repo = "siparty-release-npm-egll" + Path = "@testfolder/-/folder", + Repo = "internalrepo1" }; List results = new() { aqlResult }; @@ -524,7 +524,8 @@ public async Task GetArtifactoryRepoName_Nuget_ReturnsRepoName_ReturnsSuccess() var reponameActual = actual.First(x => x.Properties[0].Name == "internal:siemens:clearing:repo-url").Properties[0].Value; - Assert.That("siparty-release-npm-egll", Is.EqualTo(reponameActual)); + + Assert.That("internalrepo1", Is.EqualTo(reponameActual)); } [Test] public async Task GetArtifactoryRepoName_Nuget_ReturnsNotFound_ReturnsFailure() @@ -538,14 +539,14 @@ public async Task GetArtifactoryRepoName_Nuget_ReturnsNotFound_ReturnsFailure() Version = "1.0.0" }; var components = new List() { component1 }; - string[] reooListArr = { "siparty-release-npm-egll", "org1-npmjs-npm-remote-cache" }; + string[] reooListArr = { "internalrepo1", "internalrepo2" }; CommonAppSettings appSettings = new(); appSettings.Nuget = new Config() { JfrogNugetRepoList = reooListArr }; AqlResult aqlResult = new() { Name = "animation-common.1.0.0.nupkg", - Path = "@siemens-gds/saap-api-node/-/@siemens-gds", - Repo = "siparty-release-npm-egll" + Path = "@testfolder/-/folder", + Repo = "internalrepo1" }; List results = new() { aqlResult }; diff --git a/src/LCT.Services.UTest/JFrogServiceUTest.cs b/src/LCT.Services.UTest/JFrogServiceUTest.cs index 1df98a90..4a4a81b9 100644 --- a/src/LCT.Services.UTest/JFrogServiceUTest.cs +++ b/src/LCT.Services.UTest/JFrogServiceUTest.cs @@ -29,8 +29,8 @@ public async Task GetInternalComponentDataByRepo_GetsRepoInfo_Successfully() AqlResult aqlResult = new AqlResult() { - Name = "saap-api-node-2.26.3-LicenseClearing.16.sha-058fada.tgz", - Path = "@siemens-gds/saap-api-node/-/@siemens-gds", + Name = "api-node-2.26.3-LicenseClearing.16.sha-058fada.tgz", + Path = "@testfolder/-/folder", Repo = "energy-dev-npm-egll" };