Auto Bug Fix
This commit is contained in:
parent
a03e3eb199
commit
3be69b54c2
@ -200,6 +200,7 @@ public class ProcessData : IProcessData
|
|||||||
UpdateIds(httpClient, basePage, api, checkFiles);
|
UpdateIds(httpClient, basePage, api, checkFiles);
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
|
JsonPatchDocument document;
|
||||||
string ids = GetIds(httpClient, basePage, api, query);
|
string ids = GetIds(httpClient, basePage, api, query);
|
||||||
Value[] workItems = GetWorkItems(httpClient, basePage, api, ids);
|
Value[] workItems = GetWorkItems(httpClient, basePage, api, ids);
|
||||||
Task<Microsoft.TeamFoundation.WorkItemTracking.WebApi.Models.WorkItem> workItemTask;
|
Task<Microsoft.TeamFoundation.WorkItemTracking.WebApi.Models.WorkItem> workItemTask;
|
||||||
@ -215,7 +216,7 @@ public class ProcessData : IProcessData
|
|||||||
{
|
{
|
||||||
if (counter > 5)
|
if (counter > 5)
|
||||||
break;
|
break;
|
||||||
JsonPatchDocument document = new();
|
document = new();
|
||||||
if (!DateTime.TryParse(keyValuePair.Value.Submitted, out dateTime))
|
if (!DateTime.TryParse(keyValuePair.Value.Submitted, out dateTime))
|
||||||
dateTime = DateTime.MinValue;
|
dateTime = DateTime.MinValue;
|
||||||
AddPatch(document, "/fields/System.AreaPath", project);
|
AddPatch(document, "/fields/System.AreaPath", project);
|
||||||
@ -231,6 +232,17 @@ public class ProcessData : IProcessData
|
|||||||
counter++;
|
counter++;
|
||||||
if (workItemTask.Result is null)
|
if (workItemTask.Result is null)
|
||||||
continue;
|
continue;
|
||||||
|
if (keyValuePair.Value.Priority == "0 - BugFix")
|
||||||
|
{
|
||||||
|
document = new();
|
||||||
|
AddPatch(document, "/fields/System.AreaPath", project);
|
||||||
|
AddPatch(document, "/fields/System.IterationPath", project);
|
||||||
|
AddPatch(document, "/fields/System.Title", keyValuePair.Value.Title);
|
||||||
|
AddPatch(document, "/fields/System.Description", $"{description}<br />{keyValuePair.Value.Definition}");
|
||||||
|
// AddPatch(document, "/fields/System.AssignedTo", "Mike.Phares@infineon.com");
|
||||||
|
workItemTask = workItemTrackingHttpClient.CreateWorkItemAsync(document, project, "Bug");
|
||||||
|
workItemTask.Wait();
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -26,7 +26,7 @@ steps:
|
|||||||
displayName: Configuration
|
displayName: Configuration
|
||||||
|
|
||||||
- script: |
|
- script: |
|
||||||
set nugetSource=https://messa017.infineon.com/v3/index.json
|
set nugetSource=https://eaf-dev-reporting.mes.infineon.com/v3/index.json
|
||||||
echo %nugetSource%
|
echo %nugetSource%
|
||||||
echo ##vso[task.setvariable variable=NugetSource;]%nugetSource%
|
echo ##vso[task.setvariable variable=NugetSource;]%nugetSource%
|
||||||
echo $(NugetSource)
|
echo $(NugetSource)
|
||||||
|
@ -54,7 +54,6 @@
|
|||||||
<PackageReference Include="Microsoft.Extensions.Logging.Debug" Version="7.0.0" />
|
<PackageReference Include="Microsoft.Extensions.Logging.Debug" Version="7.0.0" />
|
||||||
<PackageReference Include="Microsoft.Extensions.Logging" Version="7.0.0" />
|
<PackageReference Include="Microsoft.Extensions.Logging" Version="7.0.0" />
|
||||||
<PackageReference Include="Microsoft.NET.Test.Sdk" Version="17.5.0" />
|
<PackageReference Include="Microsoft.NET.Test.Sdk" Version="17.5.0" />
|
||||||
<PackageReference Include="Microsoft.TeamFoundationServer.Client" Version="16.205.1" />
|
|
||||||
<PackageReference Include="Microsoft.Win32.SystemEvents" Version="7.0.0" />
|
<PackageReference Include="Microsoft.Win32.SystemEvents" Version="7.0.0" />
|
||||||
<PackageReference Include="MSTest.TestAdapter" Version="3.0.2" />
|
<PackageReference Include="MSTest.TestAdapter" Version="3.0.2" />
|
||||||
<PackageReference Include="MSTest.TestFramework" Version="3.0.2" />
|
<PackageReference Include="MSTest.TestFramework" Version="3.0.2" />
|
||||||
@ -68,8 +67,9 @@
|
|||||||
<PackageReference Include="Tesseract" Version="5.2.0" />
|
<PackageReference Include="Tesseract" Version="5.2.0" />
|
||||||
</ItemGroup>
|
</ItemGroup>
|
||||||
<ItemGroup>
|
<ItemGroup>
|
||||||
<PackageReference Include="Tibco.Rendezvous" Version="8.5.0" />
|
<PackageReference Include="Microsoft.TeamFoundationServer.Client" Version="16.205.1" />
|
||||||
<PackageReference Include="Infineon.Yoda" Version="5.4.1" />
|
<PackageReference Include="Infineon.Yoda" Version="5.4.1" />
|
||||||
|
<PackageReference Include="Tibco.Rendezvous" Version="8.5.0" />
|
||||||
</ItemGroup>
|
</ItemGroup>
|
||||||
<ItemGroup>
|
<ItemGroup>
|
||||||
<PackageReference Include="Infineon.Mesa.PDF.Text.Stripper" Version="4.8.0.1"><NoWarn>NU1701</NoWarn></PackageReference>
|
<PackageReference Include="Infineon.Mesa.PDF.Text.Stripper" Version="4.8.0.1"><NoWarn>NU1701</NoWarn></PackageReference>
|
||||||
|
@ -27,7 +27,7 @@ steps:
|
|||||||
|
|
||||||
- script: |
|
- script: |
|
||||||
REM set nugetSource=https://eaf-prod.mes.infineon.com/v3/index.json
|
REM set nugetSource=https://eaf-prod.mes.infineon.com/v3/index.json
|
||||||
set nugetSource=https://messa017.infineon.com/v3/index.json
|
set nugetSource=https://eaf-dev-reporting.mes.infineon.com/v3/index.json
|
||||||
echo %nugetSource%
|
echo %nugetSource%
|
||||||
echo ##vso[task.setvariable variable=NugetSource;]%nugetSource%
|
echo ##vso[task.setvariable variable=NugetSource;]%nugetSource%
|
||||||
echo $(NugetSource)
|
echo $(NugetSource)
|
||||||
|
@ -21,7 +21,7 @@ public enum Test
|
|||||||
Denton = 9,
|
Denton = 9,
|
||||||
DiffusionLength = 45,
|
DiffusionLength = 45,
|
||||||
GRATXTCenter = 51,
|
GRATXTCenter = 51,
|
||||||
GRATXTEdge = 52, //Largest
|
GRATXTEdge = 52,
|
||||||
GrowthRateXML = 50,
|
GrowthRateXML = 50,
|
||||||
Hall = 10,
|
Hall = 10,
|
||||||
HgCV = 23,
|
HgCV = 23,
|
||||||
@ -38,6 +38,7 @@ public enum Test
|
|||||||
RPMPLRatio = 17,
|
RPMPLRatio = 17,
|
||||||
RPMXY = 15,
|
RPMXY = 15,
|
||||||
SP1 = 8,
|
SP1 = 8,
|
||||||
|
SRP2100 = 53, //Largest
|
||||||
Tencor = 7,
|
Tencor = 7,
|
||||||
UV = 35,
|
UV = 35,
|
||||||
VerificationLehighton = 14,
|
VerificationLehighton = 14,
|
||||||
|
@ -78,7 +78,9 @@ public class BACKLOG : LoggingUnitTesting, IDisposable
|
|||||||
NonThrowTryCatch();
|
NonThrowTryCatch();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
#if DEBUG
|
||||||
[Ignore]
|
[Ignore]
|
||||||
|
#endif
|
||||||
[TestMethod]
|
[TestMethod]
|
||||||
public void Staging()
|
public void Staging()
|
||||||
{
|
{
|
||||||
|
96
Adaptation/_Tests/Static/MESAFIBACKLOG.cs
Normal file
96
Adaptation/_Tests/Static/MESAFIBACKLOG.cs
Normal file
@ -0,0 +1,96 @@
|
|||||||
|
using Adaptation._Tests.Shared;
|
||||||
|
using Microsoft.Extensions.Logging;
|
||||||
|
using Microsoft.VisualStudio.TestTools.UnitTesting;
|
||||||
|
using System;
|
||||||
|
using System.Diagnostics;
|
||||||
|
using System.IO;
|
||||||
|
using System.Reflection;
|
||||||
|
using System.Text;
|
||||||
|
|
||||||
|
namespace Adaptation._Tests.Static;
|
||||||
|
|
||||||
|
[TestClass]
|
||||||
|
public class MESAFIBACKLOG : LoggingUnitTesting, IDisposable
|
||||||
|
{
|
||||||
|
|
||||||
|
#pragma warning disable CA2254
|
||||||
|
#pragma warning disable IDE0060
|
||||||
|
|
||||||
|
internal static MESAFIBACKLOG LoggingUnitTesting { get; private set; }
|
||||||
|
|
||||||
|
public MESAFIBACKLOG() : base(testContext: null, declaringType: null)
|
||||||
|
{
|
||||||
|
if (LoggingUnitTesting is null)
|
||||||
|
throw new Exception();
|
||||||
|
}
|
||||||
|
|
||||||
|
public MESAFIBACKLOG(TestContext testContext) : base(testContext, new StackFrame().GetMethod().DeclaringType)
|
||||||
|
{
|
||||||
|
}
|
||||||
|
|
||||||
|
[ClassInitialize]
|
||||||
|
public static void ClassInitialize(TestContext testContext) => LoggingUnitTesting ??= new MESAFIBACKLOG(testContext);
|
||||||
|
|
||||||
|
[ClassCleanup()]
|
||||||
|
public static void ClassCleanup()
|
||||||
|
{
|
||||||
|
LoggingUnitTesting?.Logger?.LogInformation("Cleanup");
|
||||||
|
LoggingUnitTesting?.Dispose();
|
||||||
|
}
|
||||||
|
|
||||||
|
[TestMethod]
|
||||||
|
public void TestDateTime()
|
||||||
|
{
|
||||||
|
DateTime dateTime = DateTime.Now;
|
||||||
|
Assert.IsTrue(dateTime.ToString("M/d/yyyy h:mm:ss tt") == dateTime.ToString());
|
||||||
|
}
|
||||||
|
|
||||||
|
#if DEBUG
|
||||||
|
[Ignore]
|
||||||
|
#endif
|
||||||
|
[TestMethod]
|
||||||
|
public void Development()
|
||||||
|
{
|
||||||
|
MethodBase methodBase = new StackFrame().GetMethod();
|
||||||
|
StringBuilder results = new();
|
||||||
|
(string cellInstanceName, string cellInstanceVersionName)[] collection = new (string, string)[]
|
||||||
|
{
|
||||||
|
new("MESAFIBACKLOG", "v2.49.0"),
|
||||||
|
};
|
||||||
|
string staging = "http://mestsa07ec.ec.local:9003/CellInstanceServiceV2";
|
||||||
|
Shared.PasteSpecialXml.EAF.XML.API.CellInstance.CellInstanceVersion cellInstanceVersion;
|
||||||
|
LoggingUnitTesting.Logger.LogInformation(string.Concat(methodBase.Name, " - Getting configuration"));
|
||||||
|
foreach ((string cellInstanceName, string cellInstanceVersionName) in collection)
|
||||||
|
{
|
||||||
|
cellInstanceVersion = AdaptationTesting.GetCellInstanceVersion($"{staging}/{cellInstanceName}/{cellInstanceVersionName}/configuration");
|
||||||
|
_ = results.AppendLine($"{cellInstanceName}\t{cellInstanceVersionName}\t{cellInstanceVersion.EdaConnection.PortNumber}");
|
||||||
|
}
|
||||||
|
File.WriteAllText($"D:/Tmp/{methodBase.Module.Name}-{methodBase.ReflectedType.Name}-{methodBase.Name}.tsv", results.ToString());
|
||||||
|
LoggingUnitTesting.Logger.LogInformation(string.Concat(methodBase.Name, " - Exit"));
|
||||||
|
}
|
||||||
|
|
||||||
|
#if DEBUG
|
||||||
|
[Ignore]
|
||||||
|
#endif
|
||||||
|
[TestMethod]
|
||||||
|
public void Staging()
|
||||||
|
{
|
||||||
|
MethodBase methodBase = new StackFrame().GetMethod();
|
||||||
|
StringBuilder results = new();
|
||||||
|
(string cellInstanceName, string cellInstanceVersionName)[] collection = new (string, string)[]
|
||||||
|
{
|
||||||
|
new("MESAFIBACKLOG", "v2.49.0"),
|
||||||
|
};
|
||||||
|
string staging = "http://mestsa07ec.ec.local:9003/CellInstanceServiceV2";
|
||||||
|
Shared.PasteSpecialXml.EAF.XML.API.CellInstance.CellInstanceVersion cellInstanceVersion;
|
||||||
|
LoggingUnitTesting.Logger.LogInformation(string.Concat(methodBase.Name, " - Getting configuration"));
|
||||||
|
foreach ((string cellInstanceName, string cellInstanceVersionName) in collection)
|
||||||
|
{
|
||||||
|
cellInstanceVersion = AdaptationTesting.GetCellInstanceVersion($"{staging}/{cellInstanceName}/{cellInstanceVersionName}/configuration");
|
||||||
|
_ = results.AppendLine($"{cellInstanceName}\t{cellInstanceVersionName}\t{cellInstanceVersion.EdaConnection.PortNumber}");
|
||||||
|
}
|
||||||
|
File.WriteAllText($"D:/Tmp/{methodBase.Module.Name}-{methodBase.ReflectedType.Name}-{methodBase.Name}.tsv", results.ToString());
|
||||||
|
LoggingUnitTesting.Logger.LogInformation(string.Concat(methodBase.Name, " - Exit"));
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
@ -165,7 +165,7 @@ public partial class FileRead : FileReaderHandler, ISMTP
|
|||||||
Equipment.SelfDescriptionBuilder.AddParameterTypeDefinition(structuredType);
|
Equipment.SelfDescriptionBuilder.AddParameterTypeDefinition(structuredType);
|
||||||
}
|
}
|
||||||
if (!parameterTypeDefinitions.ContainsKey(jsonProperty.Value.ValueKind))
|
if (!parameterTypeDefinitions.ContainsKey(jsonProperty.Value.ValueKind))
|
||||||
throw new Exception(string.Concat('{', jsonProperty.Value.ValueKind, "} is not mapped!"));
|
throw new Exception(string.Concat('<', jsonProperty.Name, "> {", jsonProperty.Value.ValueKind, "} is not mapped!"));
|
||||||
}
|
}
|
||||||
foreach (JsonProperty jsonProperty in jsonProperties)
|
foreach (JsonProperty jsonProperty in jsonProperties)
|
||||||
{
|
{
|
||||||
|
Loading…
x
Reference in New Issue
Block a user