Compare commits
3 Commits
0ed6d17774
...
master
Author | SHA1 | Date | |
---|---|---|---|
823a31e48a | |||
552f0137df | |||
538bd194ae |
@ -22,17 +22,21 @@ public class FileRead : Shared.FileRead, IFileRead
|
|||||||
internal class PreWith
|
internal class PreWith
|
||||||
{
|
{
|
||||||
|
|
||||||
internal string MatchingFile { get; private set; }
|
|
||||||
internal string CheckFile { get; private set; }
|
|
||||||
internal string ErrFile { get; private set; }
|
internal string ErrFile { get; private set; }
|
||||||
|
internal string CheckFile { get; private set; }
|
||||||
|
internal string MatchingFile { get; private set; }
|
||||||
internal string CheckDirectory { get; private set; }
|
internal string CheckDirectory { get; private set; }
|
||||||
internal string NoWaitDirectory { get; private set; }
|
internal string NoWaitDirectory { get; private set; }
|
||||||
|
|
||||||
internal PreWith(string matchingFile, string checkFile, string errFile, string checkDirectory, string noWaitDirectory)
|
internal PreWith(string checkDirectory,
|
||||||
|
string checkFile,
|
||||||
|
string errFile,
|
||||||
|
string matchingFile,
|
||||||
|
string noWaitDirectory)
|
||||||
{
|
{
|
||||||
MatchingFile = matchingFile;
|
|
||||||
CheckFile = checkFile;
|
|
||||||
ErrFile = errFile;
|
ErrFile = errFile;
|
||||||
|
CheckFile = checkFile;
|
||||||
|
MatchingFile = matchingFile;
|
||||||
CheckDirectory = checkDirectory;
|
CheckDirectory = checkDirectory;
|
||||||
NoWaitDirectory = noWaitDirectory;
|
NoWaitDirectory = noWaitDirectory;
|
||||||
}
|
}
|
||||||
@ -221,7 +225,11 @@ public class FileRead : Shared.FileRead, IFileRead
|
|||||||
if (!Directory.Exists(checkDirectory))
|
if (!Directory.Exists(checkDirectory))
|
||||||
_ = Directory.CreateDirectory(checkDirectory);
|
_ = Directory.CreateDirectory(checkDirectory);
|
||||||
noWaitDirectory = Path.Combine(checkDirectory, "NoWaitDirectory");
|
noWaitDirectory = Path.Combine(checkDirectory, "NoWaitDirectory");
|
||||||
preWith = new(pre.MatchingFile, pre.CheckFile, errFile, checkDirectory, noWaitDirectory);
|
preWith = new(checkDirectory: checkDirectory,
|
||||||
|
checkFile: pre.CheckFile,
|
||||||
|
errFile: errFile,
|
||||||
|
matchingFile: pre.MatchingFile,
|
||||||
|
noWaitDirectory: noWaitDirectory);
|
||||||
results.Add(preWith);
|
results.Add(preWith);
|
||||||
}
|
}
|
||||||
return results.AsReadOnly();
|
return results.AsReadOnly();
|
||||||
@ -260,7 +268,7 @@ public class FileRead : Shared.FileRead, IFileRead
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
private static ReadOnlyCollection<Pre> GetPreCollection(int numberLength, string parentDirectory, ReadOnlyCollection<string> matchingFiles)
|
private static ReadOnlyCollection<Pre> GetPreCollection(int numberLength, string parentDirectory, ReadOnlyCollection<string> matchingFiles, bool _)
|
||||||
{
|
{
|
||||||
List<Pre> results = new();
|
List<Pre> results = new();
|
||||||
Pre pre;
|
Pre pre;
|
||||||
@ -275,7 +283,7 @@ public class FileRead : Shared.FileRead, IFileRead
|
|||||||
return results.AsReadOnly();
|
return results.AsReadOnly();
|
||||||
}
|
}
|
||||||
|
|
||||||
private void MoveCollection(DateTime dateTime, ProcessDataStandardFormat? processDataStandardFormat, ReadOnlyCollection<PreWith> preWithCollection)
|
private void MoveCollection(DateTime dateTime, ProcessDataStandardFormat processDataStandardFormat, ReadOnlyCollection<PreWith> preWithCollection)
|
||||||
{
|
{
|
||||||
ReadOnlyCollection<Post> postCollection = GetPostCollection(dateTime, processDataStandardFormat, preWithCollection);
|
ReadOnlyCollection<Post> postCollection = GetPostCollection(dateTime, processDataStandardFormat, preWithCollection);
|
||||||
if (postCollection.Count != 0)
|
if (postCollection.Count != 0)
|
||||||
@ -294,7 +302,7 @@ public class FileRead : Shared.FileRead, IFileRead
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
private ReadOnlyCollection<Post> GetPostCollection(DateTime dateTime, ProcessDataStandardFormat? processDataStandardFormat, ReadOnlyCollection<PreWith> preWithCollection)
|
private ReadOnlyCollection<Post> GetPostCollection(DateTime dateTime, ProcessDataStandardFormat processDataStandardFormat, ReadOnlyCollection<PreWith> preWithCollection)
|
||||||
{
|
{
|
||||||
List<Post> results = new();
|
List<Post> results = new();
|
||||||
Post post;
|
Post post;
|
||||||
@ -303,15 +311,10 @@ public class FileRead : Shared.FileRead, IFileRead
|
|||||||
{
|
{
|
||||||
if (!_IsEAFHosted)
|
if (!_IsEAFHosted)
|
||||||
continue;
|
continue;
|
||||||
if (processDataStandardFormat is null)
|
|
||||||
File.Move(preWith.MatchingFile, preWith.CheckFile);
|
|
||||||
else
|
|
||||||
{
|
|
||||||
if (!_StaticRuns.TryGetValue(_Logistics.Sequence, out List<Shared.Metrology.WS.Results>? wsResults))
|
if (!_StaticRuns.TryGetValue(_Logistics.Sequence, out List<Shared.Metrology.WS.Results>? wsResults))
|
||||||
wsResults = null;
|
wsResults = null;
|
||||||
ProcessDataStandardFormat.Write(preWith.CheckFile, processDataStandardFormat, wsResults);
|
ProcessDataStandardFormat.Write(preWith.CheckFile, processDataStandardFormat, wsResults);
|
||||||
File.Delete(preWith.MatchingFile);
|
File.Delete(preWith.MatchingFile);
|
||||||
}
|
|
||||||
if (Directory.Exists(preWith.NoWaitDirectory))
|
if (Directory.Exists(preWith.NoWaitDirectory))
|
||||||
{
|
{
|
||||||
post = new(preWith.CheckFile, preWith.ErrFile);
|
post = new(preWith.CheckFile, preWith.ErrFile);
|
||||||
@ -345,17 +348,10 @@ public class FileRead : Shared.FileRead, IFileRead
|
|||||||
private Tuple<string, Test[], JsonElement[], List<FileInfo>> GetExtractResult(string reportFullPath, DateTime dateTime)
|
private Tuple<string, Test[], JsonElement[], List<FileInfo>> GetExtractResult(string reportFullPath, DateTime dateTime)
|
||||||
{
|
{
|
||||||
Tuple<string, Test[], JsonElement[], List<FileInfo>> results = new(string.Empty, Array.Empty<Test>(), Array.Empty<JsonElement>(), new List<FileInfo>());
|
Tuple<string, Test[], JsonElement[], List<FileInfo>> results = new(string.Empty, Array.Empty<Test>(), Array.Empty<JsonElement>(), new List<FileInfo>());
|
||||||
ProcessDataStandardFormat? processDataStandardFormat = ProcessDataStandardFormat.GetProcessDataStandardFormat(reportFullPath, _ProcessDataStandardFormatMapping);
|
ProcessDataStandardFormat processDataStandardFormat = ProcessDataStandardFormat.GetProcessDataStandardFormat(reportFullPath, _ProcessDataStandardFormatMapping);
|
||||||
if (processDataStandardFormat is not null)
|
|
||||||
_Logistics = new Logistics(reportFullPath, processDataStandardFormat);
|
_Logistics = new Logistics(reportFullPath, processDataStandardFormat);
|
||||||
else
|
if (!_IsEAFHosted)
|
||||||
{
|
ProcessDataStandardFormat.Write("../../.pdsf", processDataStandardFormat, wsResults: null);
|
||||||
processDataStandardFormat = ProcessDataStandardFormat.GetProcessDataStandardFormat(reportFullPath);
|
|
||||||
_Logistics = new Logistics(reportFullPath, processDataStandardFormat);
|
|
||||||
processDataStandardFormat = null;
|
|
||||||
}
|
|
||||||
if (!_IsEAFHosted && processDataStandardFormat is not null)
|
|
||||||
ProcessDataStandardFormat.Write(".pdsf", processDataStandardFormat, wsResults: null);
|
|
||||||
SetFileParameterLotIDToLogisticsMID();
|
SetFileParameterLotIDToLogisticsMID();
|
||||||
int numberLength = 2;
|
int numberLength = 2;
|
||||||
long ticks = dateTime.Ticks;
|
long ticks = dateTime.Ticks;
|
||||||
@ -364,10 +360,16 @@ public class FileRead : Shared.FileRead, IFileRead
|
|||||||
ReadOnlyCollection<string> matchingFiles = GetMatchingFiles(ticks, reportFullPath, searchDirectories);
|
ReadOnlyCollection<string> matchingFiles = GetMatchingFiles(ticks, reportFullPath, searchDirectories);
|
||||||
if (matchingFiles.Count != searchDirectories.Count)
|
if (matchingFiles.Count != searchDirectories.Count)
|
||||||
throw new Exception($"Didn't find all files after {_BreakAfterSeconds} second(s)!");
|
throw new Exception($"Didn't find all files after {_BreakAfterSeconds} second(s)!");
|
||||||
|
if (_IsEAFHosted)
|
||||||
|
{
|
||||||
try
|
try
|
||||||
{ CreatePointerFile(numberLength, parentParentDirectory, matchingFiles); }
|
{ CreatePointerFile(numberLength, parentParentDirectory, matchingFiles); }
|
||||||
catch (Exception) { }
|
catch (Exception) { }
|
||||||
ReadOnlyCollection<Pre> preCollection = GetPreCollection(numberLength, parentParentDirectory, matchingFiles);
|
}
|
||||||
|
JsonElement[] jsonElements = ProcessDataStandardFormat.GetArray(processDataStandardFormat);
|
||||||
|
List<txt.Description> descriptions = txt.ProcessData.GetDescriptions(jsonElements);
|
||||||
|
bool mesEntityMatchesProcess = descriptions.Count > 0 && descriptions[0].MesEntity == descriptions[0].Reactor;
|
||||||
|
ReadOnlyCollection<Pre> preCollection = GetPreCollection(numberLength, parentParentDirectory, matchingFiles, mesEntityMatchesProcess);
|
||||||
ReadOnlyCollection<PreWith> preWithCollection = GetPreWithCollection(preCollection);
|
ReadOnlyCollection<PreWith> preWithCollection = GetPreWithCollection(preCollection);
|
||||||
MoveCollection(dateTime, processDataStandardFormat, preWithCollection);
|
MoveCollection(dateTime, processDataStandardFormat, preWithCollection);
|
||||||
return results;
|
return results;
|
||||||
|
@ -61,8 +61,8 @@ internal class ProcessDataStandardFormat
|
|||||||
internal static string Archive(bool addSpaces = true, char separator = ' ') =>
|
internal static string Archive(bool addSpaces = true, char separator = ' ') =>
|
||||||
GetString(SearchFor.Archive, addSpaces, separator);
|
GetString(SearchFor.Archive, addSpaces, separator);
|
||||||
|
|
||||||
internal static ProcessDataStandardFormat GetEmpty() =>
|
internal static ProcessDataStandardFormat GetEmpty(Logistics logistics) =>
|
||||||
new(new(Array.Empty<string>()), new(Array.Empty<string>()), new(Array.Empty<string>()), new(Array.Empty<string>()), null, new(new string[] { "LOGISTICS_1" }), null);
|
new(new(Array.Empty<string>()), new(Array.Empty<string>()), new(Array.Empty<string>()), new(Array.Empty<string>()), null, new(logistics.Logistics1), null);
|
||||||
|
|
||||||
internal static List<string> PDSFToFixedWidth(string reportFullPath)
|
internal static List<string> PDSFToFixedWidth(string reportFullPath)
|
||||||
{
|
{
|
||||||
@ -214,25 +214,26 @@ internal class ProcessDataStandardFormat
|
|||||||
return results.AsReadOnly();
|
return results.AsReadOnly();
|
||||||
}
|
}
|
||||||
|
|
||||||
internal static ProcessDataStandardFormat? GetProcessDataStandardFormat(string reportFullPath, ProcessDataStandardFormatMapping pdsfMapping)
|
internal static ProcessDataStandardFormat GetProcessDataStandardFormat(string reportFullPath, ProcessDataStandardFormatMapping pdsfMapping)
|
||||||
{
|
{
|
||||||
ProcessDataStandardFormat? result;
|
ProcessDataStandardFormat result;
|
||||||
const int columnsLine = 6;
|
const int columnsLine = 6;
|
||||||
FileInfo fileInfo = new(reportFullPath);
|
FileInfo fileInfo = new(reportFullPath);
|
||||||
ProcessDataStandardFormat processDataStandardFormat = GetProcessDataStandardFormat(fileInfo.LastWriteTime, pdsfMapping.NewColumnNames.Count, columnsLine, fileInfo.FullName, lines: null);
|
ProcessDataStandardFormat processDataStandardFormat = GetProcessDataStandardFormat(fileInfo.LastWriteTime, columnsLine, fileInfo.FullName, lines: null);
|
||||||
JsonElement[]? jsonElements = GetArray(pdsfMapping.NewColumnNames.Count, processDataStandardFormat, lookForNumbers: false);
|
JsonElement[]? jsonElements = pdsfMapping.OldColumnNames.Count != pdsfMapping.ColumnIndices.Count ? null : GetFullArray(processDataStandardFormat);
|
||||||
if (jsonElements is null || jsonElements.Length == 0 || pdsfMapping.OldColumnNames.Count != pdsfMapping.ColumnIndices.Count)
|
JsonProperty[]? jsonProperties = jsonElements is null || jsonElements.Length == 0 ? null : jsonElements[0].EnumerateObject().ToArray();
|
||||||
result = null;
|
if (jsonElements is null || jsonProperties is null || jsonProperties.Length != pdsfMapping.NewColumnNames.Count)
|
||||||
|
result = processDataStandardFormat;
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
result = GetProcessDataStandardFormat(pdsfMapping, jsonElements, processDataStandardFormat);
|
result = GetProcessDataStandardFormat(pdsfMapping, jsonElements, processDataStandardFormat);
|
||||||
if (result.Sequence is null || result.Columns.Count == 0 || result.Body.Count == 0 || result.Logistics.Count == 0)
|
if (result.Sequence is null || result.Columns.Count == 0 || result.Body.Count == 0 || result.Logistics.Count == 0)
|
||||||
result = null;
|
result = processDataStandardFormat;
|
||||||
}
|
}
|
||||||
return result;
|
return result;
|
||||||
}
|
}
|
||||||
|
|
||||||
private static ProcessDataStandardFormat GetProcessDataStandardFormat(DateTime lastWriteTime, int expectedColumns, int columnsLine, string path, string[]? lines)
|
private static ProcessDataStandardFormat GetProcessDataStandardFormat(DateTime lastWriteTime, int columnsLine, string path, string[]? lines)
|
||||||
{
|
{
|
||||||
ProcessDataStandardFormat result;
|
ProcessDataStandardFormat result;
|
||||||
long sequence;
|
long sequence;
|
||||||
@ -248,8 +249,6 @@ internal class ProcessDataStandardFormat
|
|||||||
else
|
else
|
||||||
{
|
{
|
||||||
segments = lines[columnsLine].Split('\t');
|
segments = lines[columnsLine].Split('\t');
|
||||||
if (segments.Length != expectedColumns)
|
|
||||||
segments = Array.Empty<string>();
|
|
||||||
for (int i = 0; i < columnsLine; i++)
|
for (int i = 0; i < columnsLine; i++)
|
||||||
header.Add(lines[i]);
|
header.Add(lines[i]);
|
||||||
}
|
}
|
||||||
@ -285,7 +284,7 @@ internal class ProcessDataStandardFormat
|
|||||||
return result;
|
return result;
|
||||||
}
|
}
|
||||||
|
|
||||||
private static JsonElement[]? GetArray(int expectedColumns, ProcessDataStandardFormat processDataStandardFormat, bool lookForNumbers)
|
private static JsonElement[]? GetFullArray(ProcessDataStandardFormat processDataStandardFormat)
|
||||||
{
|
{
|
||||||
JsonElement[]? results;
|
JsonElement[]? results;
|
||||||
if (processDataStandardFormat.Body.Count == 0 || !processDataStandardFormat.Body[0].Contains('\t'))
|
if (processDataStandardFormat.Body.Count == 0 || !processDataStandardFormat.Body[0].Contains('\t'))
|
||||||
@ -293,37 +292,19 @@ internal class ProcessDataStandardFormat
|
|||||||
else
|
else
|
||||||
{
|
{
|
||||||
string value;
|
string value;
|
||||||
string[] segments;
|
List<string> segments;
|
||||||
List<string> lines = new();
|
List<string> lines = new();
|
||||||
StringBuilder stringBuilder = new();
|
StringBuilder stringBuilder = new();
|
||||||
foreach (string bodyLine in processDataStandardFormat.Body)
|
foreach (string bodyLine in processDataStandardFormat.Body)
|
||||||
{
|
{
|
||||||
_ = stringBuilder.Clear();
|
_ = stringBuilder.Clear();
|
||||||
_ = stringBuilder.Append('{');
|
_ = stringBuilder.Append('{');
|
||||||
segments = bodyLine.Split('\t');
|
segments = bodyLine.Split('\t').ToList();
|
||||||
if (segments.Length != expectedColumns)
|
for (int c = 0; c < segments.Count; c++)
|
||||||
continue;
|
|
||||||
if (!lookForNumbers)
|
|
||||||
{
|
|
||||||
for (int c = 0; c < segments.Length; c++)
|
|
||||||
{
|
{
|
||||||
value = segments[c].Replace("\"", "\\\"").Replace("\\", "\\\\");
|
value = segments[c].Replace("\"", "\\\"").Replace("\\", "\\\\");
|
||||||
_ = stringBuilder.Append('"').Append(processDataStandardFormat.Columns[c]).Append("\":\"").Append(value).Append("\",");
|
_ = stringBuilder.Append('"').Append(processDataStandardFormat.Columns[c]).Append("\":\"").Append(value).Append("\",");
|
||||||
}
|
}
|
||||||
}
|
|
||||||
else
|
|
||||||
{
|
|
||||||
for (int c = 0; c < segments.Length; c++)
|
|
||||||
{
|
|
||||||
value = segments[c].Replace("\"", "\\\"").Replace("\\", "\\\\");
|
|
||||||
if (string.IsNullOrEmpty(value))
|
|
||||||
_ = stringBuilder.Append('"').Append(processDataStandardFormat.Columns[c]).Append("\":").Append(value).Append("null,");
|
|
||||||
else if (value.All(char.IsDigit))
|
|
||||||
_ = stringBuilder.Append('"').Append(processDataStandardFormat.Columns[c]).Append("\":").Append(value).Append(',');
|
|
||||||
else
|
|
||||||
_ = stringBuilder.Append('"').Append(processDataStandardFormat.Columns[c]).Append("\":\"").Append(value).Append("\",");
|
|
||||||
}
|
|
||||||
}
|
|
||||||
_ = stringBuilder.Remove(stringBuilder.Length - 1, 1);
|
_ = stringBuilder.Remove(stringBuilder.Length - 1, 1);
|
||||||
_ = stringBuilder.AppendLine("}");
|
_ = stringBuilder.AppendLine("}");
|
||||||
lines.Add(stringBuilder.ToString());
|
lines.Add(stringBuilder.ToString());
|
||||||
@ -379,6 +360,63 @@ internal class ProcessDataStandardFormat
|
|||||||
return result;
|
return result;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
private static string GetJson(ProcessDataStandardFormat processDataStandardFormat)
|
||||||
|
{
|
||||||
|
if (processDataStandardFormat.InputPDSF is null)
|
||||||
|
throw new NullReferenceException(nameof(processDataStandardFormat.InputPDSF));
|
||||||
|
#pragma warning disable CA1845, IDE0057
|
||||||
|
string result;
|
||||||
|
string line;
|
||||||
|
string value;
|
||||||
|
string[] segments;
|
||||||
|
List<string> lines = new();
|
||||||
|
for (int i = 0; i < processDataStandardFormat.InputPDSF.Body.Count; i++)
|
||||||
|
{
|
||||||
|
line = "{";
|
||||||
|
segments = processDataStandardFormat.InputPDSF.Body[i].Trim().Split('\t');
|
||||||
|
if (segments.Length != processDataStandardFormat.InputPDSF.Columns.Count)
|
||||||
|
break;
|
||||||
|
for (int c = 0; c < segments.Length; c++)
|
||||||
|
{
|
||||||
|
value = segments[c].Replace("\"", "\\\"").Replace("\\", "\\\\");
|
||||||
|
line += string.Concat('"', processDataStandardFormat.InputPDSF.Columns[c].Trim('"'), '"', ':', '"', value, '"', ',');
|
||||||
|
}
|
||||||
|
line = string.Concat(line.Substring(0, line.Length - 1), '}');
|
||||||
|
lines.Add(line);
|
||||||
|
}
|
||||||
|
result = string.Concat(
|
||||||
|
'{',
|
||||||
|
Environment.NewLine,
|
||||||
|
'"',
|
||||||
|
"Count",
|
||||||
|
'"',
|
||||||
|
": ",
|
||||||
|
processDataStandardFormat.Body.Count,
|
||||||
|
',',
|
||||||
|
Environment.NewLine,
|
||||||
|
'"',
|
||||||
|
"Records",
|
||||||
|
'"',
|
||||||
|
": ",
|
||||||
|
Environment.NewLine,
|
||||||
|
'[',
|
||||||
|
Environment.NewLine,
|
||||||
|
string.Join($",{Environment.NewLine}", lines),
|
||||||
|
Environment.NewLine,
|
||||||
|
']',
|
||||||
|
',',
|
||||||
|
Environment.NewLine,
|
||||||
|
'"',
|
||||||
|
"Sequence",
|
||||||
|
'"',
|
||||||
|
": ",
|
||||||
|
processDataStandardFormat.Sequence,
|
||||||
|
Environment.NewLine,
|
||||||
|
'}');
|
||||||
|
return result;
|
||||||
|
#pragma warning restore CA1845, IDE0057
|
||||||
|
}
|
||||||
|
|
||||||
internal static void Write(string path, ProcessDataStandardFormat processDataStandardFormat, List<Metrology.WS.Results>? wsResults)
|
internal static void Write(string path, ProcessDataStandardFormat processDataStandardFormat, List<Metrology.WS.Results>? wsResults)
|
||||||
{
|
{
|
||||||
List<string> results = new();
|
List<string> results = new();
|
||||||
@ -418,9 +456,10 @@ internal class ProcessDataStandardFormat
|
|||||||
results.Add($"{segments[0]}\t{segments[1][0]}_HeaderId={wsResults[0].HeaderId};{segments[1][0]}_SubgroupId={wsResults[0].SubgroupId};{segments[1]}");
|
results.Add($"{segments[0]}\t{segments[1][0]}_HeaderId={wsResults[0].HeaderId};{segments[1][0]}_SubgroupId={wsResults[0].SubgroupId};{segments[1]}");
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
results.Add("EOF");
|
results.Add("END_HEADER");
|
||||||
if (processDataStandardFormat.InputPDSF is not null)
|
if (processDataStandardFormat.InputPDSF is not null)
|
||||||
{
|
{
|
||||||
|
results.Add(string.Empty);
|
||||||
List<char> hyphens = new();
|
List<char> hyphens = new();
|
||||||
results.AddRange(processDataStandardFormat.InputPDSF.Header.Select(l => l.Replace('\t', '|')));
|
results.AddRange(processDataStandardFormat.InputPDSF.Header.Select(l => l.Replace('\t', '|')));
|
||||||
results.Add(string.Empty);
|
results.Add(string.Empty);
|
||||||
@ -431,6 +470,11 @@ internal class ProcessDataStandardFormat
|
|||||||
results.AddRange(processDataStandardFormat.InputPDSF.Body.Select(l => l.Replace('\t', '|')));
|
results.AddRange(processDataStandardFormat.InputPDSF.Body.Select(l => l.Replace('\t', '|')));
|
||||||
results.Add(string.Empty);
|
results.Add(string.Empty);
|
||||||
results.AddRange(processDataStandardFormat.InputPDSF.Footer.Select(l => l.Replace('\t', '|')));
|
results.AddRange(processDataStandardFormat.InputPDSF.Footer.Select(l => l.Replace('\t', '|')));
|
||||||
|
results.Add(string.Empty);
|
||||||
|
results.Add("EOF");
|
||||||
|
results.Add(string.Empty);
|
||||||
|
string json = GetJson(processDataStandardFormat);
|
||||||
|
results.Add(json);
|
||||||
}
|
}
|
||||||
File.WriteAllText(path, string.Join(Environment.NewLine, results));
|
File.WriteAllText(path, string.Join(Environment.NewLine, results));
|
||||||
}
|
}
|
||||||
|
@ -1,4 +1,4 @@
|
|||||||
#if true
|
#if v2_59_0
|
||||||
using Adaptation._Tests.Shared;
|
using Adaptation._Tests.Shared;
|
||||||
using Microsoft.Extensions.Logging;
|
using Microsoft.Extensions.Logging;
|
||||||
using Microsoft.VisualStudio.TestTools.UnitTesting;
|
using Microsoft.VisualStudio.TestTools.UnitTesting;
|
||||||
|
@ -1,4 +1,4 @@
|
|||||||
#if true
|
#if v2_59_0
|
||||||
using Adaptation._Tests.Shared;
|
using Adaptation._Tests.Shared;
|
||||||
using Microsoft.Extensions.Logging;
|
using Microsoft.Extensions.Logging;
|
||||||
using Microsoft.VisualStudio.TestTools.UnitTesting;
|
using Microsoft.VisualStudio.TestTools.UnitTesting;
|
||||||
|
@ -1,4 +1,4 @@
|
|||||||
#if true
|
#if v2_59_0
|
||||||
using Adaptation._Tests.Shared;
|
using Adaptation._Tests.Shared;
|
||||||
using Microsoft.Extensions.Logging;
|
using Microsoft.Extensions.Logging;
|
||||||
using Microsoft.VisualStudio.TestTools.UnitTesting;
|
using Microsoft.VisualStudio.TestTools.UnitTesting;
|
||||||
|
@ -0,0 +1,195 @@
|
|||||||
|
#if true
|
||||||
|
using Adaptation._Tests.Shared;
|
||||||
|
using Microsoft.Extensions.Logging;
|
||||||
|
using Microsoft.VisualStudio.TestTools.UnitTesting;
|
||||||
|
using System;
|
||||||
|
using System.Diagnostics;
|
||||||
|
using System.IO;
|
||||||
|
using System.Reflection;
|
||||||
|
|
||||||
|
namespace Adaptation._Tests.CreateSelfDescription.Production.v2_60_0;
|
||||||
|
|
||||||
|
[TestClass]
|
||||||
|
public class MET08DDUPSP1TBI : EAFLoggingUnitTesting
|
||||||
|
{
|
||||||
|
|
||||||
|
#pragma warning disable CA2254
|
||||||
|
#pragma warning disable IDE0060
|
||||||
|
|
||||||
|
internal static string DummyRoot { get; private set; }
|
||||||
|
internal static MET08DDUPSP1TBI EAFLoggingUnitTesting { get; private set; }
|
||||||
|
|
||||||
|
static MET08DDUPSP1TBI() => DummyRoot = @"\\mesfs.infineon.com\EC_Characterization_Si\Dummy";
|
||||||
|
|
||||||
|
public MET08DDUPSP1TBI() : base(DummyRoot, testContext: null, declaringType: null, skipEquipmentDictionary: false)
|
||||||
|
{
|
||||||
|
if (EAFLoggingUnitTesting is null)
|
||||||
|
throw new Exception();
|
||||||
|
}
|
||||||
|
|
||||||
|
public MET08DDUPSP1TBI(TestContext testContext) : base(DummyRoot, testContext, new StackFrame().GetMethod().DeclaringType, skipEquipmentDictionary: false)
|
||||||
|
{
|
||||||
|
}
|
||||||
|
|
||||||
|
[ClassInitialize]
|
||||||
|
public static void ClassInitialize(TestContext testContext)
|
||||||
|
{
|
||||||
|
EAFLoggingUnitTesting ??= new MET08DDUPSP1TBI(testContext);
|
||||||
|
EAFLoggingUnitTesting.Logger.LogInformation(string.Concat(testContext.TestName, " - ClassInitialize"));
|
||||||
|
string[] fileNameAndText = EAFLoggingUnitTesting.AdaptationTesting.GetCSharpText(testContext.TestName);
|
||||||
|
File.WriteAllText(fileNameAndText[0], fileNameAndText[1]);
|
||||||
|
File.WriteAllText(fileNameAndText[2], fileNameAndText[3]);
|
||||||
|
}
|
||||||
|
|
||||||
|
[ClassCleanup()]
|
||||||
|
public static void ClassCleanup()
|
||||||
|
{
|
||||||
|
EAFLoggingUnitTesting?.Logger?.LogInformation("Cleanup");
|
||||||
|
EAFLoggingUnitTesting?.Dispose();
|
||||||
|
}
|
||||||
|
|
||||||
|
#if DEBUG
|
||||||
|
[Ignore]
|
||||||
|
#endif
|
||||||
|
[TestMethod]
|
||||||
|
public void Production__v2_60_0__MET08DDUPSP1TBI__MoveMatchingFiles()
|
||||||
|
{
|
||||||
|
string check = "*.pdsf";
|
||||||
|
MethodBase methodBase = new StackFrame().GetMethod();
|
||||||
|
EAFLoggingUnitTesting.Logger.LogInformation(string.Concat(methodBase.Name, " - Getting configuration"));
|
||||||
|
_ = AdaptationTesting.GetWriteConfigurationGetFileRead(methodBase, check, EAFLoggingUnitTesting.AdaptationTesting);
|
||||||
|
EAFLoggingUnitTesting.Logger.LogInformation(string.Concat(methodBase.Name, " - Exit"));
|
||||||
|
}
|
||||||
|
|
||||||
|
#if DEBUG
|
||||||
|
[Ignore]
|
||||||
|
#endif
|
||||||
|
[TestMethod]
|
||||||
|
public void Production__v2_60_0__MET08DDUPSP1TBI__OpenInsightMetrologyViewer()
|
||||||
|
{
|
||||||
|
string check = "*.pdsf";
|
||||||
|
MethodBase methodBase = new StackFrame().GetMethod();
|
||||||
|
EAFLoggingUnitTesting.Logger.LogInformation(string.Concat(methodBase.Name, " - Getting configuration"));
|
||||||
|
_ = AdaptationTesting.GetWriteConfigurationGetFileRead(methodBase, check, EAFLoggingUnitTesting.AdaptationTesting);
|
||||||
|
EAFLoggingUnitTesting.Logger.LogInformation(string.Concat(methodBase.Name, " - Exit"));
|
||||||
|
}
|
||||||
|
|
||||||
|
#if DEBUG
|
||||||
|
[Ignore]
|
||||||
|
#endif
|
||||||
|
[TestMethod]
|
||||||
|
public void Production__v2_60_0__MET08DDUPSP1TBI__IQSSi()
|
||||||
|
{
|
||||||
|
string check = "*.pdsf";
|
||||||
|
MethodBase methodBase = new StackFrame().GetMethod();
|
||||||
|
EAFLoggingUnitTesting.Logger.LogInformation(string.Concat(methodBase.Name, " - Getting configuration"));
|
||||||
|
_ = AdaptationTesting.GetWriteConfigurationGetFileRead(methodBase, check, EAFLoggingUnitTesting.AdaptationTesting);
|
||||||
|
EAFLoggingUnitTesting.Logger.LogInformation(string.Concat(methodBase.Name, " - Exit"));
|
||||||
|
}
|
||||||
|
|
||||||
|
#if DEBUG
|
||||||
|
[Ignore]
|
||||||
|
#endif
|
||||||
|
[TestMethod]
|
||||||
|
public void Production__v2_60_0__MET08DDUPSP1TBI__OpenInsight()
|
||||||
|
{
|
||||||
|
string check = "*.pdsf";
|
||||||
|
MethodBase methodBase = new StackFrame().GetMethod();
|
||||||
|
EAFLoggingUnitTesting.Logger.LogInformation(string.Concat(methodBase.Name, " - Getting configuration"));
|
||||||
|
_ = AdaptationTesting.GetWriteConfigurationGetFileRead(methodBase, check, EAFLoggingUnitTesting.AdaptationTesting);
|
||||||
|
EAFLoggingUnitTesting.Logger.LogInformation(string.Concat(methodBase.Name, " - Exit"));
|
||||||
|
}
|
||||||
|
|
||||||
|
#if DEBUG
|
||||||
|
[Ignore]
|
||||||
|
#endif
|
||||||
|
[TestMethod]
|
||||||
|
public void Production__v2_60_0__MET08DDUPSP1TBI__OpenInsightMetrologyViewerAttachments()
|
||||||
|
{
|
||||||
|
string check = "*.pdsf";
|
||||||
|
MethodBase methodBase = new StackFrame().GetMethod();
|
||||||
|
EAFLoggingUnitTesting.Logger.LogInformation(string.Concat(methodBase.Name, " - Getting configuration"));
|
||||||
|
_ = AdaptationTesting.GetWriteConfigurationGetFileRead(methodBase, check, EAFLoggingUnitTesting.AdaptationTesting);
|
||||||
|
EAFLoggingUnitTesting.Logger.LogInformation(string.Concat(methodBase.Name, " - Exit"));
|
||||||
|
}
|
||||||
|
|
||||||
|
#if DEBUG
|
||||||
|
[Ignore]
|
||||||
|
#endif
|
||||||
|
[TestMethod]
|
||||||
|
public void Production__v2_60_0__MET08DDUPSP1TBI__APC()
|
||||||
|
{
|
||||||
|
string check = "*.pdsf";
|
||||||
|
MethodBase methodBase = new StackFrame().GetMethod();
|
||||||
|
EAFLoggingUnitTesting.Logger.LogInformation(string.Concat(methodBase.Name, " - Getting configuration"));
|
||||||
|
_ = AdaptationTesting.GetWriteConfigurationGetFileRead(methodBase, check, EAFLoggingUnitTesting.AdaptationTesting);
|
||||||
|
EAFLoggingUnitTesting.Logger.LogInformation(string.Concat(methodBase.Name, " - Exit"));
|
||||||
|
}
|
||||||
|
|
||||||
|
#if DEBUG
|
||||||
|
[Ignore]
|
||||||
|
#endif
|
||||||
|
[TestMethod]
|
||||||
|
public void Production__v2_60_0__MET08DDUPSP1TBI__SPaCe()
|
||||||
|
{
|
||||||
|
string check = "*.pdsf";
|
||||||
|
MethodBase methodBase = new StackFrame().GetMethod();
|
||||||
|
EAFLoggingUnitTesting.Logger.LogInformation(string.Concat(methodBase.Name, " - Getting configuration"));
|
||||||
|
_ = AdaptationTesting.GetWriteConfigurationGetFileRead(methodBase, check, EAFLoggingUnitTesting.AdaptationTesting);
|
||||||
|
EAFLoggingUnitTesting.Logger.LogInformation(string.Concat(methodBase.Name, " - Exit"));
|
||||||
|
}
|
||||||
|
|
||||||
|
#if DEBUG
|
||||||
|
[Ignore]
|
||||||
|
#endif
|
||||||
|
[TestMethod]
|
||||||
|
public void Production__v2_60_0__MET08DDUPSP1TBI__Processed()
|
||||||
|
{
|
||||||
|
string check = "*.pdsf";
|
||||||
|
MethodBase methodBase = new StackFrame().GetMethod();
|
||||||
|
EAFLoggingUnitTesting.Logger.LogInformation(string.Concat(methodBase.Name, " - Getting configuration"));
|
||||||
|
_ = AdaptationTesting.GetWriteConfigurationGetFileRead(methodBase, check, EAFLoggingUnitTesting.AdaptationTesting);
|
||||||
|
EAFLoggingUnitTesting.Logger.LogInformation(string.Concat(methodBase.Name, " - Exit"));
|
||||||
|
}
|
||||||
|
|
||||||
|
#if DEBUG
|
||||||
|
[Ignore]
|
||||||
|
#endif
|
||||||
|
[TestMethod]
|
||||||
|
public void Production__v2_60_0__MET08DDUPSP1TBI__Archive()
|
||||||
|
{
|
||||||
|
string check = "*.pdsf";
|
||||||
|
MethodBase methodBase = new StackFrame().GetMethod();
|
||||||
|
EAFLoggingUnitTesting.Logger.LogInformation(string.Concat(methodBase.Name, " - Getting configuration"));
|
||||||
|
_ = AdaptationTesting.GetWriteConfigurationGetFileRead(methodBase, check, EAFLoggingUnitTesting.AdaptationTesting);
|
||||||
|
EAFLoggingUnitTesting.Logger.LogInformation(string.Concat(methodBase.Name, " - Exit"));
|
||||||
|
}
|
||||||
|
|
||||||
|
#if DEBUG
|
||||||
|
[Ignore]
|
||||||
|
#endif
|
||||||
|
[TestMethod]
|
||||||
|
public void Production__v2_60_0__MET08DDUPSP1TBI__Dummy()
|
||||||
|
{
|
||||||
|
string check = "637400748000000000.zip";
|
||||||
|
MethodBase methodBase = new StackFrame().GetMethod();
|
||||||
|
EAFLoggingUnitTesting.Logger.LogInformation(string.Concat(methodBase.Name, " - Getting configuration"));
|
||||||
|
_ = AdaptationTesting.GetWriteConfigurationGetFileRead(methodBase, check, EAFLoggingUnitTesting.AdaptationTesting);
|
||||||
|
EAFLoggingUnitTesting.Logger.LogInformation(string.Concat(methodBase.Name, " - Exit"));
|
||||||
|
}
|
||||||
|
|
||||||
|
#if DEBUG
|
||||||
|
[Ignore]
|
||||||
|
#endif
|
||||||
|
[TestMethod]
|
||||||
|
public void Production__v2_60_0__MET08DDUPSP1TBI__TIBCO()
|
||||||
|
{
|
||||||
|
string check = "*.idc";
|
||||||
|
MethodBase methodBase = new StackFrame().GetMethod();
|
||||||
|
EAFLoggingUnitTesting.Logger.LogInformation(string.Concat(methodBase.Name, " - Getting configuration"));
|
||||||
|
_ = AdaptationTesting.GetWriteConfigurationGetFileRead(methodBase, check, EAFLoggingUnitTesting.AdaptationTesting);
|
||||||
|
EAFLoggingUnitTesting.Logger.LogInformation(string.Concat(methodBase.Name, " - Exit"));
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
|
#endif
|
@ -0,0 +1,70 @@
|
|||||||
|
#if true
|
||||||
|
using Adaptation._Tests.Shared;
|
||||||
|
using Microsoft.Extensions.Logging;
|
||||||
|
using Microsoft.VisualStudio.TestTools.UnitTesting;
|
||||||
|
using System;
|
||||||
|
using System.Diagnostics;
|
||||||
|
using System.IO;
|
||||||
|
using System.Reflection;
|
||||||
|
namespace Adaptation._Tests.CreateSelfDescription.Production.v2_60_0;
|
||||||
|
|
||||||
|
[TestClass]
|
||||||
|
public class SP101_EQPT : EAFLoggingUnitTesting
|
||||||
|
{
|
||||||
|
|
||||||
|
#pragma warning disable CA2254
|
||||||
|
#pragma warning disable IDE0060
|
||||||
|
|
||||||
|
internal static string DummyRoot { get; private set; }
|
||||||
|
internal static SP101_EQPT EAFLoggingUnitTesting { get; private set; }
|
||||||
|
|
||||||
|
static SP101_EQPT() => DummyRoot = @"\\mesfs.infineon.com\EC_Characterization_Si\Dummy";
|
||||||
|
|
||||||
|
public SP101_EQPT() : base(DummyRoot, testContext: null, declaringType: null, skipEquipmentDictionary: false)
|
||||||
|
{
|
||||||
|
if (EAFLoggingUnitTesting is null)
|
||||||
|
throw new Exception();
|
||||||
|
}
|
||||||
|
|
||||||
|
public SP101_EQPT(TestContext testContext) : base(DummyRoot, testContext, new StackFrame().GetMethod().DeclaringType, skipEquipmentDictionary: false)
|
||||||
|
{
|
||||||
|
}
|
||||||
|
|
||||||
|
[ClassInitialize]
|
||||||
|
public static void ClassInitialize(TestContext testContext)
|
||||||
|
{
|
||||||
|
EAFLoggingUnitTesting ??= new SP101_EQPT(testContext);
|
||||||
|
EAFLoggingUnitTesting.Logger.LogInformation(string.Concat(testContext.TestName, " - ClassInitialize"));
|
||||||
|
string[] fileNameAndText = EAFLoggingUnitTesting.AdaptationTesting.GetCSharpText(testContext.TestName);
|
||||||
|
File.WriteAllText(fileNameAndText[0], fileNameAndText[1]);
|
||||||
|
File.WriteAllText(fileNameAndText[2], fileNameAndText[3]);
|
||||||
|
}
|
||||||
|
|
||||||
|
[ClassCleanup()]
|
||||||
|
public static void ClassCleanup()
|
||||||
|
{
|
||||||
|
EAFLoggingUnitTesting?.Logger?.LogInformation("Cleanup");
|
||||||
|
EAFLoggingUnitTesting?.Dispose();
|
||||||
|
}
|
||||||
|
|
||||||
|
private static void NonThrowTryCatch()
|
||||||
|
{
|
||||||
|
try
|
||||||
|
{ throw new Exception(); }
|
||||||
|
catch (Exception) { }
|
||||||
|
}
|
||||||
|
|
||||||
|
[Ignore]
|
||||||
|
[TestMethod]
|
||||||
|
public void Production__v2_60_0__SP101_EQPT__MoveAllFiles()
|
||||||
|
{
|
||||||
|
string check = "*";
|
||||||
|
MethodBase methodBase = new StackFrame().GetMethod();
|
||||||
|
EAFLoggingUnitTesting.Logger.LogInformation(string.Concat(methodBase.Name, " - Getting configuration"));
|
||||||
|
_ = AdaptationTesting.GetWriteConfigurationGetFileRead(methodBase, check, EAFLoggingUnitTesting.AdaptationTesting);
|
||||||
|
EAFLoggingUnitTesting.Logger.LogInformation(string.Concat(methodBase.Name, " - Exit"));
|
||||||
|
NonThrowTryCatch();
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
|
#endif
|
@ -0,0 +1,65 @@
|
|||||||
|
#if true
|
||||||
|
using Adaptation._Tests.Shared;
|
||||||
|
using Microsoft.Extensions.Logging;
|
||||||
|
using Microsoft.VisualStudio.TestTools.UnitTesting;
|
||||||
|
using System;
|
||||||
|
using System.Diagnostics;
|
||||||
|
using System.IO;
|
||||||
|
using System.Reflection;
|
||||||
|
|
||||||
|
namespace Adaptation._Tests.CreateSelfDescription.Production.v2_60_0;
|
||||||
|
|
||||||
|
[TestClass]
|
||||||
|
public class SP101 : EAFLoggingUnitTesting
|
||||||
|
{
|
||||||
|
|
||||||
|
#pragma warning disable CA2254
|
||||||
|
#pragma warning disable IDE0060
|
||||||
|
|
||||||
|
internal static string DummyRoot { get; private set; }
|
||||||
|
internal static SP101 EAFLoggingUnitTesting { get; private set; }
|
||||||
|
|
||||||
|
static SP101() => DummyRoot = @"\\mesfs.infineon.com\EC_Characterization_Si\Dummy";
|
||||||
|
|
||||||
|
public SP101() : base(DummyRoot, testContext: null, declaringType: null, skipEquipmentDictionary: false)
|
||||||
|
{
|
||||||
|
if (EAFLoggingUnitTesting is null)
|
||||||
|
throw new Exception();
|
||||||
|
}
|
||||||
|
|
||||||
|
public SP101(TestContext testContext) : base(DummyRoot, testContext, new StackFrame().GetMethod().DeclaringType, skipEquipmentDictionary: false)
|
||||||
|
{
|
||||||
|
}
|
||||||
|
|
||||||
|
[ClassInitialize]
|
||||||
|
public static void ClassInitialize(TestContext testContext)
|
||||||
|
{
|
||||||
|
EAFLoggingUnitTesting ??= new SP101(testContext);
|
||||||
|
EAFLoggingUnitTesting.Logger.LogInformation(string.Concat(testContext.TestName, " - ClassInitialize"));
|
||||||
|
string[] fileNameAndText = EAFLoggingUnitTesting.AdaptationTesting.GetCSharpText(testContext.TestName);
|
||||||
|
File.WriteAllText(fileNameAndText[0], fileNameAndText[1]);
|
||||||
|
File.WriteAllText(fileNameAndText[2], fileNameAndText[3]);
|
||||||
|
}
|
||||||
|
|
||||||
|
[ClassCleanup()]
|
||||||
|
public static void ClassCleanup()
|
||||||
|
{
|
||||||
|
EAFLoggingUnitTesting?.Logger?.LogInformation("Cleanup");
|
||||||
|
EAFLoggingUnitTesting?.Dispose();
|
||||||
|
}
|
||||||
|
|
||||||
|
#if DEBUG
|
||||||
|
[Ignore]
|
||||||
|
#endif
|
||||||
|
[TestMethod]
|
||||||
|
public void Production__v2_60_0__SP101__txt()
|
||||||
|
{
|
||||||
|
string check = "*.txt";
|
||||||
|
MethodBase methodBase = new StackFrame().GetMethod();
|
||||||
|
EAFLoggingUnitTesting.Logger.LogInformation(string.Concat(methodBase.Name, " - Getting configuration"));
|
||||||
|
_ = AdaptationTesting.GetWriteConfigurationGetFileRead(methodBase, check, EAFLoggingUnitTesting.AdaptationTesting);
|
||||||
|
EAFLoggingUnitTesting.Logger.LogInformation(string.Concat(methodBase.Name, " - Exit"));
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
|
#endif
|
@ -1,4 +1,4 @@
|
|||||||
#if true
|
#if v2_59_0
|
||||||
using Adaptation.Shared;
|
using Adaptation.Shared;
|
||||||
using Adaptation.Shared.Methods;
|
using Adaptation.Shared.Methods;
|
||||||
using Microsoft.VisualStudio.TestTools.UnitTesting;
|
using Microsoft.VisualStudio.TestTools.UnitTesting;
|
||||||
|
@ -1,4 +1,4 @@
|
|||||||
#if true
|
#if v2_59_0
|
||||||
using Microsoft.VisualStudio.TestTools.UnitTesting;
|
using Microsoft.VisualStudio.TestTools.UnitTesting;
|
||||||
|
|
||||||
namespace Adaptation._Tests.Extract.Production.v2_59_0;
|
namespace Adaptation._Tests.Extract.Production.v2_59_0;
|
||||||
|
@ -1,4 +1,4 @@
|
|||||||
#if true
|
#if v2_59_0
|
||||||
using Adaptation.Shared;
|
using Adaptation.Shared;
|
||||||
using Adaptation.Shared.Methods;
|
using Adaptation.Shared.Methods;
|
||||||
using Microsoft.VisualStudio.TestTools.UnitTesting;
|
using Microsoft.VisualStudio.TestTools.UnitTesting;
|
||||||
|
148
Adaptation/_Tests/Extract/Production/v2.60.0/MET08DDUPSP1TBI.cs
Normal file
148
Adaptation/_Tests/Extract/Production/v2.60.0/MET08DDUPSP1TBI.cs
Normal file
@ -0,0 +1,148 @@
|
|||||||
|
#if true
|
||||||
|
using Adaptation.Shared;
|
||||||
|
using Adaptation.Shared.Methods;
|
||||||
|
using Microsoft.VisualStudio.TestTools.UnitTesting;
|
||||||
|
using System;
|
||||||
|
using System.Diagnostics;
|
||||||
|
using System.Reflection;
|
||||||
|
|
||||||
|
namespace Adaptation._Tests.Extract.Production.v2_60_0;
|
||||||
|
|
||||||
|
[TestClass]
|
||||||
|
public class MET08DDUPSP1TBI
|
||||||
|
{
|
||||||
|
|
||||||
|
#pragma warning disable CA2254
|
||||||
|
#pragma warning disable IDE0060
|
||||||
|
|
||||||
|
private static CreateSelfDescription.Production.v2_60_0.MET08DDUPSP1TBI _MET08DDUPSP1TBI;
|
||||||
|
|
||||||
|
[ClassInitialize]
|
||||||
|
public static void ClassInitialize(TestContext testContext)
|
||||||
|
{
|
||||||
|
CreateSelfDescription.Production.v2_60_0.MET08DDUPSP1TBI.ClassInitialize(testContext);
|
||||||
|
_MET08DDUPSP1TBI = CreateSelfDescription.Production.v2_60_0.MET08DDUPSP1TBI.EAFLoggingUnitTesting;
|
||||||
|
}
|
||||||
|
|
||||||
|
private static void NonThrowTryCatch()
|
||||||
|
{
|
||||||
|
try
|
||||||
|
{ throw new Exception(); }
|
||||||
|
catch (Exception) { }
|
||||||
|
}
|
||||||
|
|
||||||
|
#if DEBUG
|
||||||
|
[Ignore]
|
||||||
|
#endif
|
||||||
|
[TestMethod]
|
||||||
|
public void Production__v2_60_0__MET08DDUPSP1TBI__MoveMatchingFiles() => _MET08DDUPSP1TBI.Production__v2_60_0__MET08DDUPSP1TBI__MoveMatchingFiles();
|
||||||
|
|
||||||
|
#if DEBUG
|
||||||
|
[Ignore]
|
||||||
|
#endif
|
||||||
|
[TestMethod]
|
||||||
|
public void Production__v2_60_0__MET08DDUPSP1TBI__MoveMatchingFiles637955319879801344__Normal()
|
||||||
|
{
|
||||||
|
string check = "*.pdsf";
|
||||||
|
bool validatePDSF = false;
|
||||||
|
MethodBase methodBase = new StackFrame().GetMethod();
|
||||||
|
_MET08DDUPSP1TBI.Production__v2_60_0__MET08DDUPSP1TBI__MoveMatchingFiles();
|
||||||
|
string[] variables = _MET08DDUPSP1TBI.AdaptationTesting.GetVariables(methodBase, check, validatePDSF);
|
||||||
|
IFileRead fileRead = _MET08DDUPSP1TBI.AdaptationTesting.Get(methodBase, sourceFileLocation: variables[2], sourceFileFilter: variables[3], useCyclicalForDescription: false);
|
||||||
|
Logistics logistics = new(fileRead);
|
||||||
|
_ = Shared.AdaptationTesting.ReExtractCompareUpdatePassDirectory(variables, fileRead, logistics, validatePDSF);
|
||||||
|
NonThrowTryCatch();
|
||||||
|
}
|
||||||
|
|
||||||
|
#if DEBUG
|
||||||
|
[Ignore]
|
||||||
|
#endif
|
||||||
|
[TestMethod]
|
||||||
|
public void Production__v2_60_0__MET08DDUPSP1TBI__OpenInsightMetrologyViewer() => _MET08DDUPSP1TBI.Production__v2_60_0__MET08DDUPSP1TBI__OpenInsightMetrologyViewer();
|
||||||
|
|
||||||
|
#if DEBUG
|
||||||
|
[Ignore]
|
||||||
|
#endif
|
||||||
|
[TestMethod]
|
||||||
|
public void Production__v2_60_0__MET08DDUPSP1TBI__IQSSi() => _MET08DDUPSP1TBI.Production__v2_60_0__MET08DDUPSP1TBI__IQSSi();
|
||||||
|
|
||||||
|
#if DEBUG
|
||||||
|
[Ignore]
|
||||||
|
#endif
|
||||||
|
[TestMethod]
|
||||||
|
public void Production__v2_60_0__MET08DDUPSP1TBI__OpenInsight() => _MET08DDUPSP1TBI.Production__v2_60_0__MET08DDUPSP1TBI__OpenInsight();
|
||||||
|
|
||||||
|
#if DEBUG
|
||||||
|
[Ignore]
|
||||||
|
#endif
|
||||||
|
[TestMethod]
|
||||||
|
public void Production__v2_60_0__MET08DDUPSP1TBI__OpenInsight638052814829645888__IqsSql()
|
||||||
|
{
|
||||||
|
string check = "*.pdsf";
|
||||||
|
MethodBase methodBase = new StackFrame().GetMethod();
|
||||||
|
_MET08DDUPSP1TBI.Production__v2_60_0__MET08DDUPSP1TBI__OpenInsight();
|
||||||
|
string[] variables = _MET08DDUPSP1TBI.AdaptationTesting.GetVariables(methodBase, check, validatePDSF: false);
|
||||||
|
IFileRead fileRead = _MET08DDUPSP1TBI.AdaptationTesting.Get(methodBase, sourceFileLocation: variables[2], sourceFileFilter: variables[3], useCyclicalForDescription: false);
|
||||||
|
Logistics logistics = new(fileRead);
|
||||||
|
_ = Shared.AdaptationTesting.ReExtractCompareUpdatePassDirectory(variables, fileRead, logistics);
|
||||||
|
NonThrowTryCatch();
|
||||||
|
}
|
||||||
|
|
||||||
|
#if DEBUG
|
||||||
|
[Ignore]
|
||||||
|
#endif
|
||||||
|
[TestMethod]
|
||||||
|
public void Production__v2_60_0__MET08DDUPSP1TBI__OpenInsightMetrologyViewerAttachments() => _MET08DDUPSP1TBI.Production__v2_60_0__MET08DDUPSP1TBI__OpenInsightMetrologyViewerAttachments();
|
||||||
|
|
||||||
|
#if DEBUG
|
||||||
|
[Ignore]
|
||||||
|
#endif
|
||||||
|
[TestMethod]
|
||||||
|
public void Production__v2_60_0__MET08DDUPSP1TBI__APC() => _MET08DDUPSP1TBI.Production__v2_60_0__MET08DDUPSP1TBI__APC();
|
||||||
|
|
||||||
|
#if DEBUG
|
||||||
|
[Ignore]
|
||||||
|
#endif
|
||||||
|
[TestMethod]
|
||||||
|
public void Production__v2_60_0__MET08DDUPSP1TBI__SPaCe() => _MET08DDUPSP1TBI.Production__v2_60_0__MET08DDUPSP1TBI__SPaCe();
|
||||||
|
|
||||||
|
#if DEBUG
|
||||||
|
[Ignore]
|
||||||
|
#endif
|
||||||
|
[TestMethod]
|
||||||
|
public void Production__v2_60_0__MET08DDUPSP1TBI__Processed() => _MET08DDUPSP1TBI.Production__v2_60_0__MET08DDUPSP1TBI__Processed();
|
||||||
|
|
||||||
|
#if DEBUG
|
||||||
|
[Ignore]
|
||||||
|
#endif
|
||||||
|
[TestMethod]
|
||||||
|
public void Production__v2_60_0__MET08DDUPSP1TBI__Archive() => _MET08DDUPSP1TBI.Production__v2_60_0__MET08DDUPSP1TBI__Archive();
|
||||||
|
|
||||||
|
#if DEBUG
|
||||||
|
[Ignore]
|
||||||
|
#endif
|
||||||
|
[TestMethod]
|
||||||
|
public void Production__v2_60_0__MET08DDUPSP1TBI__Dummy() => _MET08DDUPSP1TBI.Production__v2_60_0__MET08DDUPSP1TBI__Dummy();
|
||||||
|
|
||||||
|
#if DEBUG
|
||||||
|
[Ignore]
|
||||||
|
#endif
|
||||||
|
[TestMethod]
|
||||||
|
public void Production__v2_60_0__MET08DDUPSP1TBI__TIBCO() => _MET08DDUPSP1TBI.Production__v2_60_0__MET08DDUPSP1TBI__TIBCO();
|
||||||
|
|
||||||
|
[Ignore]
|
||||||
|
[TestMethod]
|
||||||
|
public void Production__v2_60_0__MET08DDUPSP1TBI__TIBCO638217888620242702__Normal()
|
||||||
|
{
|
||||||
|
string check = "*.idc";
|
||||||
|
MethodBase methodBase = new StackFrame().GetMethod();
|
||||||
|
_MET08DDUPSP1TBI.Production__v2_60_0__MET08DDUPSP1TBI__TIBCO();
|
||||||
|
string[] variables = _MET08DDUPSP1TBI.AdaptationTesting.GetVariables(methodBase, check, validatePDSF: false);
|
||||||
|
_ = _MET08DDUPSP1TBI.AdaptationTesting.Get(methodBase, sourceFileLocation: variables[2], sourceFileFilter: variables[3], useCyclicalForDescription: false);
|
||||||
|
for (int i = 0; i < int.MaxValue; i++)
|
||||||
|
System.Threading.Thread.Sleep(500);
|
||||||
|
NonThrowTryCatch();
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
|
#endif
|
27
Adaptation/_Tests/Extract/Production/v2.60.0/SP101-EQPT.cs
Normal file
27
Adaptation/_Tests/Extract/Production/v2.60.0/SP101-EQPT.cs
Normal file
@ -0,0 +1,27 @@
|
|||||||
|
#if true
|
||||||
|
using Microsoft.VisualStudio.TestTools.UnitTesting;
|
||||||
|
|
||||||
|
namespace Adaptation._Tests.Extract.Production.v2_60_0;
|
||||||
|
|
||||||
|
[TestClass]
|
||||||
|
public class SP101_EQPT
|
||||||
|
{
|
||||||
|
|
||||||
|
#pragma warning disable CA2254
|
||||||
|
#pragma warning disable IDE0060
|
||||||
|
|
||||||
|
private static CreateSelfDescription.Production.v2_60_0.SP101_EQPT _SP101_EQPT;
|
||||||
|
|
||||||
|
[ClassInitialize]
|
||||||
|
public static void ClassInitialize(TestContext testContext)
|
||||||
|
{
|
||||||
|
CreateSelfDescription.Production.v2_60_0.SP101_EQPT.ClassInitialize(testContext);
|
||||||
|
_SP101_EQPT = CreateSelfDescription.Production.v2_60_0.SP101_EQPT.EAFLoggingUnitTesting;
|
||||||
|
}
|
||||||
|
|
||||||
|
[Ignore]
|
||||||
|
[TestMethod]
|
||||||
|
public void Production__v2_60_0__SP101_EQPT__MoveAllFiles() => _SP101_EQPT.Production__v2_60_0__SP101_EQPT__MoveAllFiles();
|
||||||
|
|
||||||
|
}
|
||||||
|
#endif
|
58
Adaptation/_Tests/Extract/Production/v2.60.0/SP101.cs
Normal file
58
Adaptation/_Tests/Extract/Production/v2.60.0/SP101.cs
Normal file
@ -0,0 +1,58 @@
|
|||||||
|
#if true
|
||||||
|
using Adaptation.Shared;
|
||||||
|
using Adaptation.Shared.Methods;
|
||||||
|
using Microsoft.VisualStudio.TestTools.UnitTesting;
|
||||||
|
using System;
|
||||||
|
using System.Diagnostics;
|
||||||
|
using System.Reflection;
|
||||||
|
|
||||||
|
namespace Adaptation._Tests.Extract.Production.v2_60_0;
|
||||||
|
|
||||||
|
[TestClass]
|
||||||
|
public class SP101
|
||||||
|
{
|
||||||
|
|
||||||
|
#pragma warning disable CA2254
|
||||||
|
#pragma warning disable IDE0060
|
||||||
|
|
||||||
|
private static CreateSelfDescription.Production.v2_60_0.SP101 _SP101;
|
||||||
|
|
||||||
|
[ClassInitialize]
|
||||||
|
public static void ClassInitialize(TestContext testContext)
|
||||||
|
{
|
||||||
|
CreateSelfDescription.Production.v2_60_0.SP101.ClassInitialize(testContext);
|
||||||
|
_SP101 = CreateSelfDescription.Production.v2_60_0.SP101.EAFLoggingUnitTesting;
|
||||||
|
}
|
||||||
|
|
||||||
|
private static void NonThrowTryCatch()
|
||||||
|
{
|
||||||
|
try
|
||||||
|
{ throw new Exception(); }
|
||||||
|
catch (Exception) { }
|
||||||
|
}
|
||||||
|
|
||||||
|
#if DEBUG
|
||||||
|
[Ignore]
|
||||||
|
#endif
|
||||||
|
[TestMethod]
|
||||||
|
public void Production__v2_60_0__SP101__txt() => _SP101.Production__v2_60_0__SP101__txt();
|
||||||
|
|
||||||
|
#if DEBUG
|
||||||
|
[Ignore]
|
||||||
|
#endif
|
||||||
|
[TestMethod]
|
||||||
|
public void Production__v2_60_0__SP101__txt637955319879801344__Normal()
|
||||||
|
{
|
||||||
|
string check = "*.txt";
|
||||||
|
bool validatePDSF = false;
|
||||||
|
_SP101.Production__v2_60_0__SP101__txt();
|
||||||
|
MethodBase methodBase = new StackFrame().GetMethod();
|
||||||
|
string[] variables = _SP101.AdaptationTesting.GetVariables(methodBase, check, validatePDSF);
|
||||||
|
IFileRead fileRead = _SP101.AdaptationTesting.Get(methodBase, sourceFileLocation: variables[2], sourceFileFilter: variables[3], useCyclicalForDescription: false);
|
||||||
|
Logistics logistics = new(fileRead);
|
||||||
|
_ = Shared.AdaptationTesting.ReExtractCompareUpdatePassDirectory(variables, fileRead, logistics, validatePDSF);
|
||||||
|
NonThrowTryCatch();
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
|
#endif
|
@ -1182,7 +1182,7 @@ public class AdaptationTesting : ISMTP
|
|||||||
Assert.IsNotNull(extractResult.Item3);
|
Assert.IsNotNull(extractResult.Item3);
|
||||||
Assert.IsNotNull(extractResult.Item4);
|
Assert.IsNotNull(extractResult.Item4);
|
||||||
if (!validatePDSF)
|
if (!validatePDSF)
|
||||||
_ = GetProcessDataStandardFormat(fileRead, logistics, extractResult, ProcessDataStandardFormat.GetEmpty());
|
_ = GetProcessDataStandardFormat(fileRead, logistics, extractResult, ProcessDataStandardFormat.GetEmpty(logistics));
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
Assert.IsTrue(extractResult.Item3.Length > 0, "extractResult Array Length check!");
|
Assert.IsTrue(extractResult.Item3.Length > 0, "extractResult Array Length check!");
|
||||||
|
@ -64,7 +64,7 @@ public class MET08DDUPSP1TBI : LoggingUnitTesting, IDisposable
|
|||||||
StringBuilder results = new();
|
StringBuilder results = new();
|
||||||
(string cellInstanceName, string cellInstanceVersionName)[] collection = new (string, string)[]
|
(string cellInstanceName, string cellInstanceVersionName)[] collection = new (string, string)[]
|
||||||
{
|
{
|
||||||
new("MET08DDUPSP1TBI", "v2.59.0"),
|
new("MET08DDUPSP1TBI", "v2.60.0"),
|
||||||
};
|
};
|
||||||
string production = "http://messa08ec.infineon.com:9003/CellInstanceServiceV2";
|
string production = "http://messa08ec.infineon.com:9003/CellInstanceServiceV2";
|
||||||
Shared.PasteSpecialXml.EAF.XML.API.CellInstance.CellInstanceVersion cellInstanceVersion;
|
Shared.PasteSpecialXml.EAF.XML.API.CellInstance.CellInstanceVersion cellInstanceVersion;
|
||||||
|
@ -203,8 +203,8 @@ public class TXT : LoggingUnitTesting, IDisposable
|
|||||||
StringBuilder results = new();
|
StringBuilder results = new();
|
||||||
(string cellInstanceName, string cellInstanceVersionName)[] collection = new (string, string)[]
|
(string cellInstanceName, string cellInstanceVersionName)[] collection = new (string, string)[]
|
||||||
{
|
{
|
||||||
new("SP101", "v2.59.0"),
|
new("SP101", "v2.60.0"),
|
||||||
new("SP101-EQPT", "v2.59.0"),
|
new("SP101-EQPT", "v2.60.0"),
|
||||||
};
|
};
|
||||||
string production = "http://messa08ec.infineon.com:9003/CellInstanceServiceV2";
|
string production = "http://messa08ec.infineon.com:9003/CellInstanceServiceV2";
|
||||||
Shared.PasteSpecialXml.EAF.XML.API.CellInstance.CellInstanceVersion cellInstanceVersion;
|
Shared.PasteSpecialXml.EAF.XML.API.CellInstance.CellInstanceVersion cellInstanceVersion;
|
||||||
|
@ -196,13 +196,13 @@
|
|||||||
<Version>7.2.4630.5</Version>
|
<Version>7.2.4630.5</Version>
|
||||||
</PackageReference>
|
</PackageReference>
|
||||||
<PackageReference Include="Infineon.EAF.Runtime">
|
<PackageReference Include="Infineon.EAF.Runtime">
|
||||||
<Version>2.59.0</Version>
|
<Version>2.60.0</Version>
|
||||||
</PackageReference>
|
</PackageReference>
|
||||||
<PackageReference Include="Pdfbox">
|
<PackageReference Include="Pdfbox">
|
||||||
<Version>1.1.1</Version>
|
<Version>1.1.1</Version>
|
||||||
</PackageReference>
|
</PackageReference>
|
||||||
<PackageReference Include="System.Text.Json">
|
<PackageReference Include="System.Text.Json">
|
||||||
<Version>8.0.3</Version>
|
<Version>8.0.5</Version>
|
||||||
</PackageReference>
|
</PackageReference>
|
||||||
</ItemGroup>
|
</ItemGroup>
|
||||||
<Import Project="$(MSBuildToolsPath)\Microsoft.CSharp.targets" />
|
<Import Project="$(MSBuildToolsPath)\Microsoft.CSharp.targets" />
|
||||||
|
@ -32,5 +32,5 @@ using System.Runtime.InteropServices;
|
|||||||
// You can specify all the values or you can default the Build and Revision Numbers
|
// You can specify all the values or you can default the Build and Revision Numbers
|
||||||
// by using the '*' as shown below:
|
// by using the '*' as shown below:
|
||||||
// [assembly: AssemblyVersion("1.0.*")]
|
// [assembly: AssemblyVersion("1.0.*")]
|
||||||
[assembly: AssemblyVersion("2.59.0.0")]
|
[assembly: AssemblyVersion("2.60.0.0")]
|
||||||
[assembly: AssemblyFileVersion("2.59.0.0")]
|
[assembly: AssemblyFileVersion("2.60.0.0")]
|
||||||
|
Reference in New Issue
Block a user