Skip to content

Commit

Permalink
getting the specific version of the release URL for nuget IT
Browse files Browse the repository at this point in the history
  • Loading branch information
adityanarayanp committed Dec 6, 2023
1 parent 793273b commit df6f9f6
Showing 1 changed file with 2 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@
using Newtonsoft.Json;
using NUnit.Framework;
using System.IO;
using System.Linq;
using System.Net.Http;
using System.Net.Http.Headers;
using System.Threading.Tasks;
Expand Down Expand Up @@ -148,7 +149,7 @@ public async Task ReleaseCreation__AfterSuccessfulExeRun_ReturnsClearingStateAsN
string url = TestConstant.Sw360ReleaseApi + TestConstant.componentNameUrl + "Newtonsoft.Json";
string responseBody = await httpClient.GetStringAsync(url);//GET method
var responseData = JsonConvert.DeserializeObject<ReleaseIdOfComponent>(responseBody);
string urlofreleaseid = responseData.Embedded.Sw360Releases[0].Links.Self.Href;
string urlofreleaseid = responseData.Embedded.Sw360Releases.First(x => x.Version == "12.0.3").Links.Self.Href.ToString();
string responseForRelease = await httpClient.GetStringAsync(urlofreleaseid);//GET method for fetching the release details
var responseDataForRelease = JsonConvert.DeserializeObject<Releases>(responseForRelease);

Expand Down

0 comments on commit df6f9f6

Please sign in to comment.