Compare commits
	
		
			20 Commits
		
	
	
		
			5e1e8f2364
			...
			master
		
	
	| Author | SHA1 | Date | |
|---|---|---|---|
| 5f8c79e087 | |||
| 5a5c478419 | |||
| 318012cd1c | |||
| a6743c4de5 | |||
| 333174a887 | |||
| cdf30b6bfe | |||
| 5e9f9e7a57 | |||
| c5e45a7afd | |||
| f0ec303ddb | |||
| 61fea7c581 | |||
| f8421a092b | |||
| f218f59247 | |||
| 8e5314a9e3 | |||
| da4888ef8f | |||
| 483e5a3610 | |||
| bdfe3c3934 | |||
| b9152f7520 | |||
| 1ca8d303fb | |||
| 2b21f30797 | |||
| dd342eb236 | 
| @ -110,7 +110,7 @@ dotnet_diagnostic.CA2254.severity = none # CA2254: The logging message template | ||||
| dotnet_diagnostic.IDE0001.severity = warning # IDE0001: Simplify name | ||||
| dotnet_diagnostic.IDE0002.severity = warning # Simplify (member access) - System.Version.Equals("1", "2"); Version.Equals("1", "2"); | ||||
| dotnet_diagnostic.IDE0004.severity = warning # IDE0004: Cast is redundant. | ||||
| dotnet_diagnostic.IDE0005.severity = warning # Using directive is unnecessary | ||||
| dotnet_diagnostic.IDE0005.severity = none # Using directive is unnecessary | ||||
| dotnet_diagnostic.IDE0028.severity = none # IDE0028: Collection initialization can be simplified | ||||
| dotnet_diagnostic.IDE0031.severity = warning # Use null propagation (IDE0031) | ||||
| dotnet_diagnostic.IDE0047.severity = warning # IDE0047: Parentheses can be removed | ||||
| @ -122,6 +122,8 @@ dotnet_diagnostic.IDE0290.severity = none # Use primary constructor [Distance]cs | ||||
| dotnet_diagnostic.IDE0300.severity = none # IDE0300: Collection initialization can be simplified | ||||
| dotnet_diagnostic.IDE0301.severity = none #IDE0301: Collection initialization can be simplified | ||||
| dotnet_diagnostic.IDE0305.severity = none # IDE0305: Collection initialization can be simplified | ||||
| dotnet_diagnostic.MSTEST0015.severity = none # MSTEST0015: Test method {method} should not be ignored | ||||
| dotnet_diagnostic.MSTEST0037.severity = error # MSTEST0037: Use proper 'Assert' methods | ||||
| dotnet_diagnostic.SYSLIB1045.severity = none # SYSLIB1045: diagnostics for regex source generation | ||||
| dotnet_naming_rule.abstract_method_should_be_pascal_case.severity = warning | ||||
| dotnet_naming_rule.abstract_method_should_be_pascal_case.style = pascal_case | ||||
|  | ||||
							
								
								
									
										39
									
								
								Adaptation/.vscode/launch.json
									
									
									
									
										vendored
									
									
								
							
							
						
						
									
										39
									
								
								Adaptation/.vscode/launch.json
									
									
									
									
										vendored
									
									
								
							| @ -1,10 +1,43 @@ | ||||
| { | ||||
|   "configurations": [ | ||||
|     { | ||||
|       "mode": "debug", | ||||
|       "name": "Go launch file", | ||||
|       "program": "${file}", | ||||
|       "request": "launch", | ||||
|       "type": "go" | ||||
|     }, | ||||
|     { | ||||
|       "name": "node Launch Current Opened File", | ||||
|       "program": "${file}", | ||||
|       "request": "launch", | ||||
|       "type": "node" | ||||
|     }, | ||||
|     { | ||||
|       "cwd": "${workspaceFolder}", | ||||
|       "internalConsoleOptions": "neverOpen", | ||||
|       "name": "Debug File", | ||||
|       "program": "${file}", | ||||
|       "request": "launch", | ||||
|       "stopOnEntry": false, | ||||
|       "type": "bun", | ||||
|       "watchMode": false | ||||
|     }, | ||||
|     { | ||||
|       "cwd": "${workspaceFolder}", | ||||
|       "internalConsoleOptions": "neverOpen", | ||||
|       "name": "Run File", | ||||
|       "noDebug": true, | ||||
|       "program": "${file}", | ||||
|       "request": "launch", | ||||
|       "type": "bun", | ||||
|       "watchMode": false | ||||
|     }, | ||||
|     { | ||||
|       "name": ".NET Core Attach", | ||||
|       "type": "coreclr", | ||||
|       "processId": 32760, | ||||
|       "request": "attach", | ||||
|       "processId": 6456 | ||||
|       "type": "coreclr" | ||||
|     } | ||||
|   ] | ||||
| } | ||||
| } | ||||
							
								
								
									
										161
									
								
								Adaptation/.vscode/tasks.json
									
									
									
									
										vendored
									
									
								
							
							
						
						
									
										161
									
								
								Adaptation/.vscode/tasks.json
									
									
									
									
										vendored
									
									
								
							| @ -1,19 +1,134 @@ | ||||
| { | ||||
|     "version": "2.0.0", | ||||
|     "inputs": [ | ||||
|         { | ||||
|             "default": "Development", | ||||
|             "description": "Which ASP Net Core Environment?", | ||||
|             "id": "ASPNETCORE_ENVIRONMENT", | ||||
|             "options": [ | ||||
|                 "Development", | ||||
|                 "Production" | ||||
|             ], | ||||
|             "type": "pickString" | ||||
|         }, | ||||
|         { | ||||
|             "default": "{AssemblyTitle}", | ||||
|             "description": "What Assembly Title?", | ||||
|             "id": "AssemblyTitle", | ||||
|             "type": "promptString" | ||||
|         }, | ||||
|         { | ||||
|             "default": "{Build.BuildId}", | ||||
|             "description": "Which Build BuildId?", | ||||
|             "id": "Build.BuildId", | ||||
|             "type": "promptString" | ||||
|         }, | ||||
|         { | ||||
|             "default": "{Build.Reason}", | ||||
|             "description": "Which Build Reason?", | ||||
|             "id": "Build.Reason", | ||||
|             "type": "promptString" | ||||
|         }, | ||||
|         { | ||||
|             "default": "{Build.Repository.Id}", | ||||
|             "description": "Which Build Repository Id?", | ||||
|             "id": "Build.Repository.Id", | ||||
|             "type": "promptString" | ||||
|         }, | ||||
|         { | ||||
|             "default": "{Build.Repository.Name}", | ||||
|             "description": "Which Build Repository Name?", | ||||
|             "id": "Build.Repository.Name", | ||||
|             "type": "promptString" | ||||
|         }, | ||||
|         { | ||||
|             "default": "{Build.SourceVersion}", | ||||
|             "description": "Which Build Source Version?", | ||||
|             "id": "Build.SourceVersion", | ||||
|             "type": "promptString" | ||||
|         }, | ||||
|         { | ||||
|             "default": "Debug", | ||||
|             "description": "Which Configuration?", | ||||
|             "id": "Configuration", | ||||
|             "options": [ | ||||
|                 "Debug", | ||||
|                 "Release" | ||||
|             ], | ||||
|             "type": "pickString" | ||||
|         }, | ||||
|         { | ||||
|             "default": "net8.0", | ||||
|             "description": "Which Core Version?", | ||||
|             "id": "CoreVersion", | ||||
|             "options": [ | ||||
|                 "net8.0" | ||||
|             ], | ||||
|             "type": "pickString" | ||||
|         }, | ||||
|         { | ||||
|             "default": "C:/Program Files (x86)/Microsoft Visual Studio/2022/BuildTools/MSBuild/Current/Bin/MSBuild.exe", | ||||
|             "description": "Which MS Build?", | ||||
|             "id": "MSBuild", | ||||
|             "type": "promptString" | ||||
|         }, | ||||
|         { | ||||
|             "default": "https://artifactory.intra.infineon.com/artifactory/api/nuget/ngt-fi-package-main-vir/", | ||||
|             "description": "Which Nuget Source?", | ||||
|             "id": "NugetSource", | ||||
|             "type": "promptString" | ||||
|         }, | ||||
|         { | ||||
|             "default": "win-x64", | ||||
|             "description": "Which Runtime?", | ||||
|             "id": "Runtime", | ||||
|             "options": [ | ||||
|                 "win-x64", | ||||
|                 "win-x32", | ||||
|                 "linux-x64", | ||||
|                 "linux-x32" | ||||
|             ], | ||||
|             "type": "pickString" | ||||
|         }, | ||||
|         { | ||||
|             "default": "L:/", | ||||
|             "description": "Which System DefaultWorkingDirectory?", | ||||
|             "id": "System.DefaultWorkingDirectory", | ||||
|             "options": [ | ||||
|                 "L:/", | ||||
|                 "D:/", | ||||
|                 "C:/" | ||||
|             ], | ||||
|             "type": "pickString" | ||||
|         }, | ||||
|         { | ||||
|             "default": "v4.8", | ||||
|             "description": "Which Core Target Framework Version?", | ||||
|             "id": "TargetFrameworkVersion", | ||||
|             "options": [ | ||||
|                 "v4.8" | ||||
|             ], | ||||
|             "type": "pickString" | ||||
|         }, | ||||
|         { | ||||
|             "default": "{UserSecretsId}", | ||||
|             "description": "Which Core User Secrets Id?", | ||||
|             "id": "UserSecretsId", | ||||
|             "type": "promptString" | ||||
|         } | ||||
|     ], | ||||
|     "tasks": [ | ||||
|         { | ||||
|             "label": "Build", | ||||
|             "command": "dotnet", | ||||
|             "type": "process", | ||||
|             "args": [ | ||||
|                 "build", | ||||
|                 "/property:GenerateFullPaths=true", | ||||
|                 "/consoleloggerparameters:NoSummary" | ||||
|                 "build" | ||||
|             ], | ||||
|             "problemMatcher": "$msCompile" | ||||
|         }, | ||||
|         { | ||||
|             "label": "Test-Debug", | ||||
|             "label": "Test Debug", | ||||
|             "command": "dotnet", | ||||
|             "type": "process", | ||||
|             "args": [ | ||||
| @ -24,7 +139,7 @@ | ||||
|             "problemMatcher": "$msCompile" | ||||
|         }, | ||||
|         { | ||||
|             "label": "Test-Release", | ||||
|             "label": "Test Release", | ||||
|             "command": "dotnet", | ||||
|             "type": "process", | ||||
|             "args": [ | ||||
| @ -50,7 +165,7 @@ | ||||
|             "problemMatcher": "$msCompile" | ||||
|         }, | ||||
|         { | ||||
|             "label": "Format-Whitespaces", | ||||
|             "label": "Format Whitespaces", | ||||
|             "command": "dotnet", | ||||
|             "type": "process", | ||||
|             "args": [ | ||||
| @ -78,7 +193,7 @@ | ||||
|             "args": [ | ||||
|                 "/target:Build", | ||||
|                 "/restore:True", | ||||
|                 "/p:RestoreSources=https://artifactory.intra.infineon.com/artifactory/api/nuget/ngt-fi-package-main-vir/%3Bhttps://packagemanagement.eu.infineon.com:4430/api/v2/%3Bhttps://tfs.intra.infineon.com/tfs/FactoryIntegration/_packaging/EAF/nuget/v3/index.json%3Bhttps://tfs.intra.infineon.com/tfs/FactoryIntegration/_packaging/EAF%40Local/nuget/v3/index.json%3Bhttps://api.nuget.org/v3/index.json", | ||||
|                 "/p:RestoreSources=https://artifactory.intra.infineon.com/artifactory/api/nuget/ngt-fi-package-main-vir/%3Bhttps://tfs.intra.infineon.com/tfs/FactoryIntegration/_packaging/EAF/nuget/v3/index.json%3Bhttps://tfs.intra.infineon.com/tfs/FactoryIntegration/_packaging/EAF%40Local/nuget/v3/index.json%3Bhttps://api.nuget.org/v3/index.json", | ||||
|                 "/detailedsummary", | ||||
|                 "/consoleloggerparameters:PerformanceSummary;ErrorsOnly;", | ||||
|                 "/property:Configuration=Debug;TargetFrameworkVersion=v4.8", | ||||
| @ -86,6 +201,38 @@ | ||||
|             ], | ||||
|             "problemMatcher": "$msCompile" | ||||
|         }, | ||||
|         { | ||||
|             "label": "Code Project", | ||||
|             "type": "shell", | ||||
|             "command": "code ../MET08RESIMAPCDE.csproj", | ||||
|             "problemMatcher": [] | ||||
|         }, | ||||
|         { | ||||
|             "label": "Code Read Me", | ||||
|             "type": "shell", | ||||
|             "command": "code ../README.md", | ||||
|             "problemMatcher": [] | ||||
|         }, | ||||
|         { | ||||
|             "label": "File-Folder-Helper AOT s X Day-Helper-2025-03-20", | ||||
|             "type": "shell", | ||||
|             "command": "L:/DevOps/Mesa_FI/File-Folder-Helper/bin/Release/net8.0/win-x64/publish/File-Folder-Helper.exe", | ||||
|             "args": [ | ||||
|                 "s", | ||||
|                 "X", | ||||
|                 "L:/DevOps/EAF-Mesa-Integration/MET08RESIMAPCDE", | ||||
|                 "Day-Helper-2025-03-20", | ||||
|                 "false", | ||||
|                 "4" | ||||
|             ], | ||||
|             "problemMatcher": [] | ||||
|         }, | ||||
|         { | ||||
|             "label": "Code Git Config", | ||||
|             "type": "shell", | ||||
|             "command": "code ../.git/config", | ||||
|             "problemMatcher": [] | ||||
|         }, | ||||
|         { | ||||
|             "label": "Kanbn Console", | ||||
|             "type": "npm", | ||||
|  | ||||
| @ -14,7 +14,7 @@ namespace Adaptation.FileHandlers.APC; | ||||
| public class FileRead : Shared.FileRead, IFileRead | ||||
| { | ||||
|  | ||||
|     public FileRead(ISMTP smtp, Dictionary<string, string> fileParameter, string cellInstanceName, int? connectionCount, string cellInstanceConnectionName, FileConnectorConfiguration fileConnectorConfiguration, string equipmentTypeName, string parameterizedModelObjectDefinitionType, IList<ModelObjectParameterDefinition> modelObjectParameters, string equipmentDictionaryName, Dictionary<string, List<long>> dummyRuns, Dictionary<long, List<string>> staticRuns, bool useCyclicalForDescription, bool isEAFHosted) : | ||||
|     public FileRead(ISMTP smtp, Dictionary<string, string> fileParameter, string cellInstanceName, int? connectionCount, string cellInstanceConnectionName, FileConnectorConfiguration fileConnectorConfiguration, string equipmentTypeName, string parameterizedModelObjectDefinitionType, IList<ModelObjectParameterDefinition> modelObjectParameters, string equipmentDictionaryName, Dictionary<string, List<long>> dummyRuns, Dictionary<long, List<Shared.Metrology.WS.Results>> staticRuns, bool useCyclicalForDescription, bool isEAFHosted) : | ||||
|         base(new Description(), false, smtp, fileParameter, cellInstanceName, connectionCount, cellInstanceConnectionName, fileConnectorConfiguration, equipmentTypeName, parameterizedModelObjectDefinitionType, modelObjectParameters, equipmentDictionaryName, dummyRuns, staticRuns, useCyclicalForDescription, isEAFHosted: connectionCount is null) | ||||
|     { | ||||
|         _MinFileLength = 10; | ||||
| @ -120,15 +120,15 @@ public class FileRead : Shared.FileRead, IFileRead | ||||
|     private Tuple<string, Test[], JsonElement[], List<FileInfo>> GetExtractResult(string reportFullPath, DateTime dateTime) | ||||
|     { | ||||
|         Tuple<string, Test[], JsonElement[], List<FileInfo>> results; | ||||
|         Tuple<string, string[], string[]> pdsf = ProcessDataStandardFormat.GetLogisticsColumnsAndBody(reportFullPath); | ||||
|         _Logistics = new Logistics(reportFullPath, pdsf.Item1); | ||||
|         ProcessDataStandardFormat processDataStandardFormat = ProcessDataStandardFormat.GetProcessDataStandardFormat(reportFullPath); | ||||
|         _Logistics = new Logistics(reportFullPath, processDataStandardFormat); | ||||
|         SetFileParameterLotIDToLogisticsMID(); | ||||
|         JsonElement[] jsonElements = ProcessDataStandardFormat.GetArray(pdsf); | ||||
|         JsonElement[] jsonElements = ProcessDataStandardFormat.GetArray(processDataStandardFormat); | ||||
|         List<Shared.Properties.IDescription> descriptions = GetDuplicatorDescriptions(jsonElements); | ||||
|         Test[] tests = (from l in descriptions select (Test)l.Test).ToArray(); | ||||
|         if (_IsEAFHosted && _FileConnectorConfiguration.FileScanningIntervalInSeconds > 0) | ||||
|             FileCopy(reportFullPath, dateTime, descriptions); | ||||
|         results = new Tuple<string, Test[], JsonElement[], List<FileInfo>>(pdsf.Item1, tests, jsonElements, new List<FileInfo>()); | ||||
|         results = new Tuple<string, Test[], JsonElement[], List<FileInfo>>(string.Join(Environment.NewLine, processDataStandardFormat.Logistics), tests, jsonElements, new List<FileInfo>()); | ||||
|         return results; | ||||
|     } | ||||
|  | ||||
|  | ||||
| @ -18,7 +18,7 @@ public class FileRead : Shared.FileRead, IFileRead | ||||
|     private readonly string _JobIdParentDirectory; | ||||
|     private readonly string _JobIdArchiveParentDirectory; | ||||
|  | ||||
|     public FileRead(ISMTP smtp, Dictionary<string, string> fileParameter, string cellInstanceName, int? connectionCount, string cellInstanceConnectionName, FileConnectorConfiguration fileConnectorConfiguration, string equipmentTypeName, string parameterizedModelObjectDefinitionType, IList<ModelObjectParameterDefinition> modelObjectParameters, string equipmentDictionaryName, Dictionary<string, List<long>> dummyRuns, Dictionary<long, List<string>> staticRuns, bool useCyclicalForDescription, bool isEAFHosted) : | ||||
|     public FileRead(ISMTP smtp, Dictionary<string, string> fileParameter, string cellInstanceName, int? connectionCount, string cellInstanceConnectionName, FileConnectorConfiguration fileConnectorConfiguration, string equipmentTypeName, string parameterizedModelObjectDefinitionType, IList<ModelObjectParameterDefinition> modelObjectParameters, string equipmentDictionaryName, Dictionary<string, List<long>> dummyRuns, Dictionary<long, List<Shared.Metrology.WS.Results>> staticRuns, bool useCyclicalForDescription, bool isEAFHosted) : | ||||
|         base(new Description(), false, smtp, fileParameter, cellInstanceName, connectionCount, cellInstanceConnectionName, fileConnectorConfiguration, equipmentTypeName, parameterizedModelObjectDefinitionType, modelObjectParameters, equipmentDictionaryName, dummyRuns, staticRuns, useCyclicalForDescription, isEAFHosted: connectionCount is null) | ||||
|     { | ||||
|         _MinFileLength = 10; | ||||
| @ -120,9 +120,10 @@ public class FileRead : Shared.FileRead, IFileRead | ||||
|         if (dateTime == DateTime.MinValue) | ||||
|             throw new ArgumentNullException(nameof(dateTime)); | ||||
|         string logisticsSequence = _Logistics.Sequence.ToString(); | ||||
|         string day = $"{_Logistics.DateTimeFromSequence:yyyy-MM-dd}"; | ||||
|         string weekOfYear = _Calendar.GetWeekOfYear(_Logistics.DateTimeFromSequence, CalendarWeekRule.FirstDay, DayOfWeek.Sunday).ToString("00"); | ||||
|         string weekDirectory = $"{_Logistics.DateTimeFromSequence:yyyy}_Week_{weekOfYear}{@"\"}{_Logistics.DateTimeFromSequence:yyyy-MM-dd}"; | ||||
|         string destinationArchiveDirectory = Path.Combine(_JobIdArchiveParentDirectory, _Logistics.JobID, weekDirectory); | ||||
|         string weekDirectory = $"{_Logistics.DateTimeFromSequence:yyyy}_Week_{weekOfYear}"; | ||||
|         string destinationArchiveDirectory = Path.Combine(_JobIdArchiveParentDirectory, _Logistics.JobID, weekDirectory, day); | ||||
|         if (!Directory.Exists(destinationArchiveDirectory)) | ||||
|             _ = Directory.CreateDirectory(destinationArchiveDirectory); | ||||
|         string jobIdDirectory = Path.Combine(_JobIdParentDirectory, _Logistics.JobID); | ||||
| @ -144,15 +145,15 @@ public class FileRead : Shared.FileRead, IFileRead | ||||
|     private Tuple<string, Test[], JsonElement[], List<FileInfo>> GetExtractResult(string reportFullPath, DateTime dateTime) | ||||
|     { | ||||
|         Tuple<string, Test[], JsonElement[], List<FileInfo>> results; | ||||
|         Tuple<string, string[], string[]> pdsf = ProcessDataStandardFormat.GetLogisticsColumnsAndBody(reportFullPath); | ||||
|         _Logistics = new Logistics(reportFullPath, pdsf.Item1); | ||||
|         ProcessDataStandardFormat processDataStandardFormat = ProcessDataStandardFormat.GetProcessDataStandardFormat(reportFullPath); | ||||
|         _Logistics = new Logistics(reportFullPath, processDataStandardFormat); | ||||
|         SetFileParameterLotIDToLogisticsMID(); | ||||
|         JsonElement[] jsonElements = ProcessDataStandardFormat.GetArray(pdsf); | ||||
|         JsonElement[] jsonElements = ProcessDataStandardFormat.GetArray(processDataStandardFormat); | ||||
|         List<Shared.Properties.IDescription> descriptions = GetDuplicatorDescriptions(jsonElements); | ||||
|         Test[] tests = (from l in descriptions select (Test)l.Test).ToArray(); | ||||
|         if (_IsEAFHosted && _FileConnectorConfiguration.FileScanningIntervalInSeconds > 0) | ||||
|             MoveArchive(reportFullPath, dateTime); | ||||
|         results = new Tuple<string, Test[], JsonElement[], List<FileInfo>>(pdsf.Item1, tests, jsonElements, new List<FileInfo>()); | ||||
|         results = new Tuple<string, Test[], JsonElement[], List<FileInfo>>(string.Join(Environment.NewLine, processDataStandardFormat.Logistics), tests, jsonElements, new List<FileInfo>()); | ||||
|         return results; | ||||
|     } | ||||
|  | ||||
|  | ||||
| @ -9,7 +9,7 @@ namespace Adaptation.FileHandlers; | ||||
| public class CellInstanceConnectionName | ||||
| { | ||||
|  | ||||
|     internal static IFileRead Get(ISMTP smtp, Dictionary<string, string> fileParameter, string cellInstanceName, string cellInstanceConnectionName, FileConnectorConfiguration fileConnectorConfiguration, string equipmentTypeName, string parameterizedModelObjectDefinitionType, IList<ModelObjectParameterDefinition> modelObjectParameters, string equipmentDictionaryName, Dictionary<string, List<long>> dummyRuns, Dictionary<long, List<string>> staticRuns, bool useCyclicalForDescription, int? connectionCount) | ||||
|     internal static IFileRead Get(ISMTP smtp, Dictionary<string, string> fileParameter, string cellInstanceName, string cellInstanceConnectionName, FileConnectorConfiguration fileConnectorConfiguration, string equipmentTypeName, string parameterizedModelObjectDefinitionType, IList<ModelObjectParameterDefinition> modelObjectParameters, string equipmentDictionaryName, Dictionary<string, List<long>> dummyRuns, Dictionary<long, List<Shared.Metrology.WS.Results>> staticRuns, bool useCyclicalForDescription, int? connectionCount) | ||||
|     { | ||||
|         IFileRead result = cellInstanceConnectionName switch | ||||
|         { | ||||
| @ -22,7 +22,6 @@ public class CellInstanceConnectionName | ||||
|             nameof(OpenInsight) => new OpenInsight.FileRead(smtp, fileParameter, cellInstanceName, connectionCount, cellInstanceConnectionName, fileConnectorConfiguration, equipmentTypeName, parameterizedModelObjectDefinitionType, modelObjectParameters, equipmentDictionaryName, dummyRuns, staticRuns, useCyclicalForDescription, isEAFHosted: connectionCount is null), | ||||
|             nameof(OpenInsightMetrologyViewer) => new OpenInsightMetrologyViewer.FileRead(smtp, fileParameter, cellInstanceName, connectionCount, cellInstanceConnectionName, fileConnectorConfiguration, equipmentTypeName, parameterizedModelObjectDefinitionType, modelObjectParameters, equipmentDictionaryName, dummyRuns, staticRuns, useCyclicalForDescription, isEAFHosted: connectionCount is null), | ||||
|             nameof(OpenInsightMetrologyViewerAttachments) => new OpenInsightMetrologyViewerAttachments.FileRead(smtp, fileParameter, cellInstanceName, connectionCount, cellInstanceConnectionName, fileConnectorConfiguration, equipmentTypeName, parameterizedModelObjectDefinitionType, modelObjectParameters, equipmentDictionaryName, dummyRuns, staticRuns, useCyclicalForDescription, isEAFHosted: connectionCount is null), | ||||
|             nameof(txt) => new txt.FileRead(smtp, fileParameter, cellInstanceName, connectionCount, cellInstanceConnectionName, fileConnectorConfiguration, equipmentTypeName, parameterizedModelObjectDefinitionType, modelObjectParameters, equipmentDictionaryName, dummyRuns, staticRuns, useCyclicalForDescription, isEAFHosted: connectionCount is null), | ||||
|             nameof(Processed) => new Processed.FileRead(smtp, fileParameter, cellInstanceName, connectionCount, cellInstanceConnectionName, fileConnectorConfiguration, equipmentTypeName, parameterizedModelObjectDefinitionType, modelObjectParameters, equipmentDictionaryName, dummyRuns, staticRuns, useCyclicalForDescription, isEAFHosted: connectionCount is null), | ||||
|             nameof(RsM) => new RsM.FileRead(smtp, fileParameter, cellInstanceName, connectionCount, cellInstanceConnectionName, fileConnectorConfiguration, equipmentTypeName, parameterizedModelObjectDefinitionType, modelObjectParameters, equipmentDictionaryName, dummyRuns, staticRuns, useCyclicalForDescription, isEAFHosted: connectionCount is null), | ||||
|             nameof(SPaCe) => new SPaCe.FileRead(smtp, fileParameter, cellInstanceName, connectionCount, cellInstanceConnectionName, fileConnectorConfiguration, equipmentTypeName, parameterizedModelObjectDefinitionType, modelObjectParameters, equipmentDictionaryName, dummyRuns, staticRuns, useCyclicalForDescription, isEAFHosted: connectionCount is null), | ||||
|  | ||||
| @ -22,7 +22,7 @@ public class FileRead : Shared.FileRead, IFileRead | ||||
|     private readonly HttpClient _HttpClient; | ||||
|     private readonly string _StaticFileServer; | ||||
|  | ||||
|     public FileRead(ISMTP smtp, Dictionary<string, string> fileParameter, string cellInstanceName, int? connectionCount, string cellInstanceConnectionName, FileConnectorConfiguration fileConnectorConfiguration, string equipmentTypeName, string parameterizedModelObjectDefinitionType, IList<ModelObjectParameterDefinition> modelObjectParameters, string equipmentDictionaryName, Dictionary<string, List<long>> dummyRuns, Dictionary<long, List<string>> staticRuns, bool useCyclicalForDescription, bool isEAFHosted) : | ||||
|     public FileRead(ISMTP smtp, Dictionary<string, string> fileParameter, string cellInstanceName, int? connectionCount, string cellInstanceConnectionName, FileConnectorConfiguration fileConnectorConfiguration, string equipmentTypeName, string parameterizedModelObjectDefinitionType, IList<ModelObjectParameterDefinition> modelObjectParameters, string equipmentDictionaryName, Dictionary<string, List<long>> dummyRuns, Dictionary<long, List<Shared.Metrology.WS.Results>> staticRuns, bool useCyclicalForDescription, bool isEAFHosted) : | ||||
|         base(new Description(), false, smtp, fileParameter, cellInstanceName, connectionCount, cellInstanceConnectionName, fileConnectorConfiguration, equipmentTypeName, parameterizedModelObjectDefinitionType, modelObjectParameters, equipmentDictionaryName, dummyRuns, staticRuns, useCyclicalForDescription, isEAFHosted: connectionCount is null) | ||||
|     { | ||||
|         _MinFileLength = 10; | ||||
|  | ||||
| @ -23,7 +23,7 @@ public class FileRead : Shared.FileRead, IFileRead | ||||
|     private int _LastDummyRunIndex; | ||||
|     private readonly string[] _CellNames; | ||||
|  | ||||
|     public FileRead(ISMTP smtp, Dictionary<string, string> fileParameter, string cellInstanceName, int? connectionCount, string cellInstanceConnectionName, FileConnectorConfiguration fileConnectorConfiguration, string equipmentTypeName, string parameterizedModelObjectDefinitionType, IList<ModelObjectParameterDefinition> modelObjectParameters, string equipmentDictionaryName, Dictionary<string, List<long>> dummyRuns, Dictionary<long, List<string>> staticRuns, bool useCyclicalForDescription, bool isEAFHosted) : | ||||
|     public FileRead(ISMTP smtp, Dictionary<string, string> fileParameter, string cellInstanceName, int? connectionCount, string cellInstanceConnectionName, FileConnectorConfiguration fileConnectorConfiguration, string equipmentTypeName, string parameterizedModelObjectDefinitionType, IList<ModelObjectParameterDefinition> modelObjectParameters, string equipmentDictionaryName, Dictionary<string, List<long>> dummyRuns, Dictionary<long, List<Shared.Metrology.WS.Results>> staticRuns, bool useCyclicalForDescription, bool isEAFHosted) : | ||||
|         base(new Description(), false, smtp, fileParameter, cellInstanceName, connectionCount, cellInstanceConnectionName, fileConnectorConfiguration, equipmentTypeName, parameterizedModelObjectDefinitionType, modelObjectParameters, equipmentDictionaryName, dummyRuns, staticRuns, useCyclicalForDescription, isEAFHosted: connectionCount is null) | ||||
|     { | ||||
|         _MinFileLength = 10; | ||||
|  | ||||
| @ -14,7 +14,7 @@ namespace Adaptation.FileHandlers.IQSSi; | ||||
| public class FileRead : Shared.FileRead, IFileRead | ||||
| { | ||||
|  | ||||
|     public FileRead(ISMTP smtp, Dictionary<string, string> fileParameter, string cellInstanceName, int? connectionCount, string cellInstanceConnectionName, FileConnectorConfiguration fileConnectorConfiguration, string equipmentTypeName, string parameterizedModelObjectDefinitionType, IList<ModelObjectParameterDefinition> modelObjectParameters, string equipmentDictionaryName, Dictionary<string, List<long>> dummyRuns, Dictionary<long, List<string>> staticRuns, bool useCyclicalForDescription, bool isEAFHosted) : | ||||
|     public FileRead(ISMTP smtp, Dictionary<string, string> fileParameter, string cellInstanceName, int? connectionCount, string cellInstanceConnectionName, FileConnectorConfiguration fileConnectorConfiguration, string equipmentTypeName, string parameterizedModelObjectDefinitionType, IList<ModelObjectParameterDefinition> modelObjectParameters, string equipmentDictionaryName, Dictionary<string, List<long>> dummyRuns, Dictionary<long, List<Shared.Metrology.WS.Results>> staticRuns, bool useCyclicalForDescription, bool isEAFHosted) : | ||||
|         base(new Description(), false, smtp, fileParameter, cellInstanceName, connectionCount, cellInstanceConnectionName, fileConnectorConfiguration, equipmentTypeName, parameterizedModelObjectDefinitionType, modelObjectParameters, equipmentDictionaryName, dummyRuns, staticRuns, useCyclicalForDescription, isEAFHosted: connectionCount is null) | ||||
|     { | ||||
|         _MinFileLength = 10; | ||||
| @ -103,7 +103,7 @@ public class FileRead : Shared.FileRead, IFileRead | ||||
|         return results; | ||||
|     } | ||||
|  | ||||
|     private void FileCopy<T>(string reportFullPath, DateTime dateTime, List<T> descriptions) where T : Shared.Properties.IDescription | ||||
|     private void WriteFile<T>(string reportFullPath, DateTime dateTime, List<T> descriptions) where T : Shared.Properties.IDescription | ||||
|     { | ||||
|         bool isDummyRun = false; | ||||
|         string successDirectory = string.Empty; | ||||
| @ -111,23 +111,24 @@ public class FileRead : Shared.FileRead, IFileRead | ||||
|         string duplicateDirectory = Path.Combine(_FileConnectorConfiguration.SourceFileLocation, _CellInstanceName); | ||||
|         if (!Directory.Exists(duplicateDirectory)) | ||||
|             _ = Directory.CreateDirectory(duplicateDirectory); | ||||
|         string duplicateFile = Path.Combine(duplicateDirectory, Path.GetFileName(reportFullPath)); | ||||
|         File.Copy(reportFullPath, duplicateFile, overwrite: true); | ||||
|         string duplicateFile = Path.Combine(duplicateDirectory, $"{Path.GetFileName(reportFullPath)}.xml"); | ||||
|         string xml = ProcessDataStandardFormat.GetXml(reportFullPath); | ||||
|         File.WriteAllText(duplicateFile, xml); | ||||
|         WaitForFileConsumption(dateTime, descriptions, isDummyRun, successDirectory, duplicateDirectory, collection, duplicateFile); | ||||
|     } | ||||
|  | ||||
|     private Tuple<string, Test[], JsonElement[], List<FileInfo>> GetExtractResult(string reportFullPath, DateTime dateTime) | ||||
|     { | ||||
|         Tuple<string, Test[], JsonElement[], List<FileInfo>> results; | ||||
|         Tuple<string, string[], string[]> pdsf = ProcessDataStandardFormat.GetLogisticsColumnsAndBody(reportFullPath); | ||||
|         _Logistics = new Logistics(reportFullPath, pdsf.Item1); | ||||
|         ProcessDataStandardFormat processDataStandardFormat = ProcessDataStandardFormat.GetProcessDataStandardFormat(reportFullPath); | ||||
|         _Logistics = new Logistics(reportFullPath, processDataStandardFormat); | ||||
|         SetFileParameterLotIDToLogisticsMID(); | ||||
|         JsonElement[] jsonElements = ProcessDataStandardFormat.GetArray(pdsf); | ||||
|         JsonElement[] jsonElements = ProcessDataStandardFormat.GetArray(processDataStandardFormat); | ||||
|         List<Shared.Properties.IDescription> descriptions = GetDuplicatorDescriptions(jsonElements); | ||||
|         Test[] tests = (from l in descriptions select (Test)l.Test).ToArray(); | ||||
|         if (_IsEAFHosted && _FileConnectorConfiguration.FileScanningIntervalInSeconds > 0) | ||||
|             FileCopy(reportFullPath, dateTime, descriptions); | ||||
|         results = new Tuple<string, Test[], JsonElement[], List<FileInfo>>(pdsf.Item1, tests, jsonElements, new List<FileInfo>()); | ||||
|             WriteFile(reportFullPath, dateTime, descriptions); | ||||
|         results = new Tuple<string, Test[], JsonElement[], List<FileInfo>>(string.Join(Environment.NewLine, processDataStandardFormat.Logistics), tests, jsonElements, new List<FileInfo>()); | ||||
|         return results; | ||||
|     } | ||||
|  | ||||
|  | ||||
| @ -5,17 +5,75 @@ using Adaptation.Shared.Duplicator; | ||||
| using Adaptation.Shared.Methods; | ||||
| using System; | ||||
| using System.Collections.Generic; | ||||
| using System.Collections.ObjectModel; | ||||
| using System.IO; | ||||
| using System.Linq; | ||||
| using System.Text; | ||||
| using System.Text.Json; | ||||
| using System.Threading; | ||||
|  | ||||
| namespace Adaptation.FileHandlers.MoveMatchingFiles; | ||||
|  | ||||
| #nullable enable | ||||
|  | ||||
| public class FileRead : Shared.FileRead, IFileRead | ||||
| { | ||||
|  | ||||
|     public FileRead(ISMTP smtp, Dictionary<string, string> fileParameter, string cellInstanceName, int? connectionCount, string cellInstanceConnectionName, FileConnectorConfiguration fileConnectorConfiguration, string equipmentTypeName, string parameterizedModelObjectDefinitionType, IList<ModelObjectParameterDefinition> modelObjectParameters, string equipmentDictionaryName, Dictionary<string, List<long>> dummyRuns, Dictionary<long, List<string>> staticRuns, bool useCyclicalForDescription, bool isEAFHosted) : | ||||
|     internal class PreWith | ||||
|     { | ||||
|  | ||||
|         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 NoWaitDirectory { get; private set; } | ||||
|  | ||||
|         internal PreWith(string checkDirectory, | ||||
|                          string checkFile, | ||||
|                          string errFile, | ||||
|                          string matchingFile, | ||||
|                          string noWaitDirectory) | ||||
|         { | ||||
|             ErrFile = errFile; | ||||
|             CheckFile = checkFile; | ||||
|             MatchingFile = matchingFile; | ||||
|             CheckDirectory = checkDirectory; | ||||
|             NoWaitDirectory = noWaitDirectory; | ||||
|         } | ||||
|  | ||||
|     } | ||||
|  | ||||
|     internal class Pre | ||||
|     { | ||||
|  | ||||
|         internal string MatchingFile { get; private set; } | ||||
|         internal string CheckFile { get; private set; } | ||||
|  | ||||
|         internal Pre(string matchingFile, string checkFile) | ||||
|         { | ||||
|             MatchingFile = matchingFile; | ||||
|             CheckFile = checkFile; | ||||
|         } | ||||
|  | ||||
|     } | ||||
|  | ||||
|     internal class Post | ||||
|     { | ||||
|  | ||||
|         internal string ErrFile { get; private set; } | ||||
|         internal string CheckFile { get; private set; } | ||||
|  | ||||
|         internal Post(string checkFile, string errFile) | ||||
|         { | ||||
|             ErrFile = errFile; | ||||
|             CheckFile = checkFile; | ||||
|         } | ||||
|  | ||||
|     } | ||||
|  | ||||
|     private readonly ProcessDataStandardFormatMapping _ProcessDataStandardFormatMapping; | ||||
|  | ||||
|     public FileRead(ISMTP smtp, Dictionary<string, string> fileParameter, string cellInstanceName, int? connectionCount, string cellInstanceConnectionName, FileConnectorConfiguration fileConnectorConfiguration, string equipmentTypeName, string parameterizedModelObjectDefinitionType, IList<ModelObjectParameterDefinition> modelObjectParameters, string equipmentDictionaryName, Dictionary<string, List<long>> dummyRuns, Dictionary<long, List<Shared.Metrology.WS.Results>> staticRuns, bool useCyclicalForDescription, bool isEAFHosted) : | ||||
|         base(new Description(), false, smtp, fileParameter, cellInstanceName, connectionCount, cellInstanceConnectionName, fileConnectorConfiguration, equipmentTypeName, parameterizedModelObjectDefinitionType, modelObjectParameters, equipmentDictionaryName, dummyRuns, staticRuns, useCyclicalForDescription, isEAFHosted: connectionCount is null) | ||||
|     { | ||||
|         _MinFileLength = 10; | ||||
| @ -27,6 +85,12 @@ public class FileRead : Shared.FileRead, IFileRead | ||||
|             throw new Exception(cellInstanceConnectionName); | ||||
|         if (!_IsDuplicator) | ||||
|             throw new Exception(cellInstanceConnectionName); | ||||
|         string processDataStandardFormatMappingOldColumnNames = GetPropertyValue(cellInstanceConnectionName, modelObjectParameters, "Process.Data.Standard.Format.Mapping.Old.Column.Names"); | ||||
|         string processDataStandardFormatMappingNewColumnNames = GetPropertyValue(cellInstanceConnectionName, modelObjectParameters, "Process.Data.Standard.Format.Mapping.New.Column.Names"); | ||||
|         string processDataStandardFormatMappingColumnIndices = GetPropertyValue(cellInstanceConnectionName, modelObjectParameters, "Process.Data.Standard.Format.Mapping.Column.Indices"); | ||||
|         _ProcessDataStandardFormatMapping = ProcessDataStandardFormatMapping.Get(processDataStandardFormatMappingOldColumnNames, | ||||
|                                                                                  processDataStandardFormatMappingNewColumnNames, | ||||
|                                                                                  processDataStandardFormatMappingColumnIndices); | ||||
|     } | ||||
|  | ||||
|     void IFileRead.Move(Tuple<string, Test[], JsonElement[], List<FileInfo>> extractResults, Exception exception) | ||||
| @ -41,7 +105,8 @@ public class FileRead : Shared.FileRead, IFileRead | ||||
|         Move(extractResults); | ||||
|     } | ||||
|  | ||||
|     void IFileRead.WaitForThread() => WaitForThread(thread: null, threadExceptions: null); | ||||
|     void IFileRead.WaitForThread() => | ||||
|         WaitForThread(thread: null, threadExceptions: null); | ||||
|  | ||||
|     string IFileRead.GetEventDescription() | ||||
|     { | ||||
| @ -88,7 +153,7 @@ public class FileRead : Shared.FileRead, IFileRead | ||||
|         DateTime dateTime = DateTime.Now; | ||||
|         results = GetExtractResult(reportFullPath, dateTime); | ||||
|         if (results.Item3 is null) | ||||
|             results = new Tuple<string, Test[], JsonElement[], List<FileInfo>>(results.Item1, Array.Empty<Test>(), JsonSerializer.Deserialize<JsonElement[]>("[]"), results.Item4); | ||||
|             results = new Tuple<string, Test[], JsonElement[], List<FileInfo>>(results.Item1, Array.Empty<Test>(), JsonSerializer.Deserialize<JsonElement[]>("[]") ?? throw new Exception(), results.Item4); | ||||
|         if (results.Item3.Length > 0 && _IsEAFHosted) | ||||
|             WritePDSF(this, results.Item3); | ||||
|         UpdateLastTicksDuration(DateTime.Now.Ticks - dateTime.Ticks); | ||||
| @ -104,7 +169,33 @@ public class FileRead : Shared.FileRead, IFileRead | ||||
|         return results; | ||||
|     } | ||||
|  | ||||
|     private static List<string> GetSearchDirectories(int numberLength, string parentDirectory) | ||||
|     private static ReadOnlyCollection<PreWith> GetPreWithCollection(ReadOnlyCollection<Pre> preCollection) | ||||
|     { | ||||
|         List<PreWith> results = new(); | ||||
|         string errFile; | ||||
|         PreWith preWith; | ||||
|         string? checkDirectory; | ||||
|         string noWaitDirectory; | ||||
|         foreach (Pre pre in preCollection) | ||||
|         { | ||||
|             errFile = string.Concat(pre.CheckFile, ".err"); | ||||
|             checkDirectory = Path.GetDirectoryName(pre.CheckFile); | ||||
|             if (string.IsNullOrEmpty(checkDirectory)) | ||||
|                 continue; | ||||
|             if (!Directory.Exists(checkDirectory)) | ||||
|                 _ = Directory.CreateDirectory(checkDirectory); | ||||
|             noWaitDirectory = Path.Combine(checkDirectory, "NoWaitDirectory"); | ||||
|             preWith = new(checkDirectory: checkDirectory, | ||||
|                           checkFile: pre.CheckFile, | ||||
|                           errFile: errFile, | ||||
|                           matchingFile: pre.MatchingFile, | ||||
|                           noWaitDirectory: noWaitDirectory); | ||||
|             results.Add(preWith); | ||||
|         } | ||||
|         return results.AsReadOnly(); | ||||
|     } | ||||
|  | ||||
|     private static ReadOnlyCollection<string> GetSearchDirectories(int numberLength, string parentDirectory) | ||||
|     { | ||||
|         List<string> results = new(); | ||||
|         string[] directories = Directory.GetDirectories(parentDirectory, "*", SearchOption.TopDirectoryOnly); | ||||
| @ -115,10 +206,138 @@ public class FileRead : Shared.FileRead, IFileRead | ||||
|             results.Add(directory); | ||||
|         } | ||||
|         results.Sort(); | ||||
|         return results.AsReadOnly(); | ||||
|     } | ||||
|  | ||||
|     private static void CreatePointerFile(int numberLength, string parentDirectory, ReadOnlyCollection<string> matchingFiles) | ||||
|     { | ||||
|         string checkFile; | ||||
|         string writeFile; | ||||
|         string? directoryName; | ||||
|         int parentDirectoryLength = parentDirectory.Length; | ||||
|         foreach (string matchingFile in matchingFiles) | ||||
|         { | ||||
|             directoryName = Path.GetDirectoryName(matchingFile); | ||||
|             if (directoryName is null) | ||||
|                 continue; | ||||
|             checkFile = $"{matchingFile[0]}{directoryName.Substring(parentDirectoryLength + numberLength + 1)}"; | ||||
|             writeFile = Path.Combine(parentDirectory, $"{directoryName.Substring(parentDirectory.Length + 1, numberLength)}.txt"); | ||||
|             if (File.Exists(writeFile)) | ||||
|                 continue; | ||||
|             File.AppendAllLines(writeFile, new string[] { parentDirectory, matchingFile, directoryName, checkFile }); | ||||
|         } | ||||
|     } | ||||
|  | ||||
|     private static ReadOnlyCollection<Pre> GetPreCollection(int numberLength, string parentDirectory, ReadOnlyCollection<string> matchingFiles) | ||||
|     { | ||||
|         List<Pre> results = new(); | ||||
|         Pre pre; | ||||
|         string checkFile; | ||||
|         int parentDirectoryLength = parentDirectory.Length; | ||||
|         foreach (string matchingFile in matchingFiles) | ||||
|         { | ||||
|             checkFile = $"{matchingFile[0]}{matchingFile.Substring(parentDirectoryLength + numberLength + 1)}"; | ||||
|             pre = new(matchingFile, checkFile); | ||||
|             results.Add(pre); | ||||
|         } | ||||
|         return results.AsReadOnly(); | ||||
|     } | ||||
|  | ||||
|     private void MoveCollection(DateTime dateTime, ProcessDataStandardFormat processDataStandardFormat, ReadOnlyCollection<PreWith> preWithCollection) | ||||
|     { | ||||
|         ReadOnlyCollection<Post> postCollection = GetPostCollection(dateTime, processDataStandardFormat, preWithCollection); | ||||
|         if (postCollection.Count != 0) | ||||
|         { | ||||
|             Thread.Sleep(500); | ||||
|             StringBuilder stringBuilder = new(); | ||||
|             foreach (Post post in postCollection) | ||||
|             { | ||||
|                 if (File.Exists(post.ErrFile)) | ||||
|                     _ = stringBuilder.AppendLine(File.ReadAllText(post.ErrFile)); | ||||
|                 if (File.Exists(post.CheckFile)) | ||||
|                     _ = stringBuilder.AppendLine($"<{post.CheckFile}> was not consumed by the end!"); | ||||
|             } | ||||
|             if (stringBuilder.Length > 0) | ||||
|                 throw new Exception(stringBuilder.ToString()); | ||||
|         } | ||||
|     } | ||||
|  | ||||
|     private ReadOnlyCollection<Post> GetPostCollection(DateTime dateTime, ProcessDataStandardFormat processDataStandardFormat, ReadOnlyCollection<PreWith> preWithCollection) | ||||
|     { | ||||
|         List<Post> results = new(); | ||||
|         Post post; | ||||
|         long preWait; | ||||
|         foreach (PreWith preWith in preWithCollection) | ||||
|         { | ||||
|             if (!_IsEAFHosted) | ||||
|                 continue; | ||||
|             if (!_StaticRuns.TryGetValue(_Logistics.Sequence, out List<Shared.Metrology.WS.Results>? wsResults)) | ||||
|                 wsResults = null; | ||||
|             if (processDataStandardFormat.InputPDSF is null) | ||||
|                 File.Move(preWith.MatchingFile, preWith.CheckFile); | ||||
|             else | ||||
|             { | ||||
|                 ProcessDataStandardFormat.Write(preWith.CheckFile, processDataStandardFormat, wsResults); | ||||
|                 File.Delete(preWith.MatchingFile); | ||||
|             } | ||||
|             if (Directory.Exists(preWith.NoWaitDirectory)) | ||||
|             { | ||||
|                 post = new(preWith.CheckFile, preWith.ErrFile); | ||||
|                 results.Add(post); | ||||
|                 continue; | ||||
|             } | ||||
|             if (_FileConnectorConfiguration?.FileHandleWaitTime is null) | ||||
|                 preWait = DateTime.Now.AddMilliseconds(1234).Ticks; | ||||
|             else | ||||
|                 preWait = DateTime.Now.AddMilliseconds(_FileConnectorConfiguration.FileHandleWaitTime.Value).Ticks; | ||||
|             for (short i = 0; i < short.MaxValue; i++) | ||||
|             { | ||||
|                 if (DateTime.Now.Ticks > preWait) | ||||
|                     break; | ||||
|                 Thread.Sleep(500); | ||||
|             } | ||||
|             for (int i = 0; i < int.MaxValue; i++) | ||||
|             { | ||||
|                 if (File.Exists(preWith.ErrFile)) | ||||
|                     throw new Exception(File.ReadAllText(preWith.ErrFile)); | ||||
|                 if (!File.Exists(preWith.CheckFile)) | ||||
|                     break; | ||||
|                 if (new TimeSpan(DateTime.Now.Ticks - dateTime.Ticks).TotalSeconds > _BreakAfterSeconds) | ||||
|                     throw new Exception($"Not all files were consumed after {_BreakAfterSeconds} second(s)!"); | ||||
|                 Thread.Sleep(500); | ||||
|             } | ||||
|         } | ||||
|         return results.AsReadOnly(); | ||||
|     } | ||||
|  | ||||
|     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>()); | ||||
|         ProcessDataStandardFormat processDataStandardFormat = ProcessDataStandardFormat.GetProcessDataStandardFormat(reportFullPath, _ProcessDataStandardFormatMapping); | ||||
|         _Logistics = new Logistics(reportFullPath, processDataStandardFormat); | ||||
|         if (!_IsEAFHosted) | ||||
|             ProcessDataStandardFormat.Write("../../.pdsf", processDataStandardFormat, wsResults: null); | ||||
|         SetFileParameterLotIDToLogisticsMID(); | ||||
|         int numberLength = 2; | ||||
|         long ticks = dateTime.Ticks; | ||||
|         string parentParentDirectory = GetParentParent(reportFullPath); | ||||
|         ReadOnlyCollection<string> searchDirectories = GetSearchDirectories(numberLength, parentParentDirectory); | ||||
|         ReadOnlyCollection<string> matchingFiles = GetMatchingFiles(ticks, reportFullPath, searchDirectories); | ||||
|         if (matchingFiles.Count != searchDirectories.Count) | ||||
|             throw new Exception($"Didn't find all files after {_BreakAfterSeconds} second(s)!"); | ||||
|         if (_IsEAFHosted) | ||||
|         { | ||||
|             try | ||||
|             { CreatePointerFile(numberLength, parentParentDirectory, matchingFiles); } | ||||
|             catch (Exception) { } | ||||
|         } | ||||
|         ReadOnlyCollection<Pre> preCollection = GetPreCollection(numberLength, parentParentDirectory, matchingFiles); | ||||
|         ReadOnlyCollection<PreWith> preWithCollection = GetPreWithCollection(preCollection); | ||||
|         MoveCollection(dateTime, processDataStandardFormat, preWithCollection); | ||||
|         return results; | ||||
|     } | ||||
|  | ||||
|     private List<string> GetMatchingFiles(long ticks, string reportFullPath, List<string> searchDirectories) | ||||
|     private ReadOnlyCollection<string> GetMatchingFiles(long ticks, string reportFullPath, ReadOnlyCollection<string> searchDirectories) | ||||
|     { | ||||
|         List<string> results = new(); | ||||
|         string[] found; | ||||
| @ -137,129 +356,7 @@ public class FileRead : Shared.FileRead, IFileRead | ||||
|                     break; | ||||
|             } | ||||
|         } | ||||
|         return results; | ||||
|     } | ||||
|  | ||||
|     private static List<(string matchingFile, string checkFile)> GetCollection(int numberLength, string parentDirectory, List<string> matchingFiles) | ||||
|     { | ||||
|         List<(string matchingFile, string checkFile)> results = new(); | ||||
|         string checkFile; | ||||
|         int parentDirectoryLength = parentDirectory.Length; | ||||
|         foreach (string matchingFile in matchingFiles) | ||||
|         { | ||||
|             checkFile = $"{matchingFile[0]}{matchingFile.Substring(parentDirectoryLength + numberLength + 1)}"; | ||||
|             results.Add(new(matchingFile, checkFile)); | ||||
|         } | ||||
|         return results; | ||||
|     } | ||||
|  | ||||
|     private static List<(string, string, string, string, string)> GetCollection(List<(string matchingFile, string checkFile)> collection) | ||||
|     { | ||||
|         List<(string, string, string, string, string)> results = new(); | ||||
|         string errFile; | ||||
|         string checkDirectory; | ||||
|         string noWaitDirectory; | ||||
|         foreach ((string matchingFile, string checkFile) in collection) | ||||
|         { | ||||
|             errFile = string.Concat(checkFile, ".err"); | ||||
|             checkDirectory = Path.GetDirectoryName(checkFile); | ||||
|             if (!Directory.Exists(checkDirectory)) | ||||
|                 _ = Directory.CreateDirectory(checkDirectory); | ||||
|             noWaitDirectory = Path.Combine(checkDirectory, "NoWaitDirectory"); | ||||
|             results.Add(new(matchingFile, checkFile, errFile, checkDirectory, noWaitDirectory)); | ||||
|         } | ||||
|         return results; | ||||
|     } | ||||
|  | ||||
|     private void MoveCollection(DateTime dateTime, List<(string matchingFile, string checkFile)> collection) | ||||
|     { | ||||
|         long preWait; | ||||
|         List<(string checkFile, string errFile)> postCollection = new(); | ||||
|         foreach ((string matchingFile, string checkFile, string errFile, string checkDirectory, string noWaitDirectory) in GetCollection(collection)) | ||||
|         { | ||||
|             File.Move(matchingFile, checkFile); | ||||
|             if (Directory.Exists(noWaitDirectory)) | ||||
|             { | ||||
|                 postCollection.Add(new(checkFile, errFile)); | ||||
|                 continue; | ||||
|             } | ||||
|             if (_FileConnectorConfiguration?.FileHandleWaitTime is null) | ||||
|                 preWait = DateTime.Now.AddMilliseconds(1234).Ticks; | ||||
|             else | ||||
|                 preWait = DateTime.Now.AddMilliseconds(_FileConnectorConfiguration.FileHandleWaitTime.Value).Ticks; | ||||
|             for (short i = 0; i < short.MaxValue; i++) | ||||
|             { | ||||
|                 if (DateTime.Now.Ticks > preWait) | ||||
|                     break; | ||||
|                 Thread.Sleep(500); | ||||
|             } | ||||
|             for (int i = 0; i < int.MaxValue; i++) | ||||
|             { | ||||
|                 if (File.Exists(errFile)) | ||||
|                     throw new Exception(File.ReadAllText(errFile)); | ||||
|                 if (!File.Exists(checkFile)) | ||||
|                     break; | ||||
|                 if (new TimeSpan(DateTime.Now.Ticks - dateTime.Ticks).TotalSeconds > _BreakAfterSeconds) | ||||
|                     throw new Exception($"Not all files were consumed after {_BreakAfterSeconds} second(s)!"); | ||||
|                 Thread.Sleep(500); | ||||
|             } | ||||
|         } | ||||
|         if (postCollection.Count != 0) | ||||
|         { | ||||
|             Thread.Sleep(500); | ||||
|             StringBuilder stringBuilder = new(); | ||||
|             foreach ((string checkFile, string errFile) in postCollection) | ||||
|             { | ||||
|                 if (File.Exists(errFile)) | ||||
|                     _ = stringBuilder.AppendLine(File.ReadAllText(errFile)); | ||||
|                 if (File.Exists(checkFile)) | ||||
|                     _ = stringBuilder.AppendLine($"<{checkFile}> was not consumed by the end!"); | ||||
|             } | ||||
|             if (stringBuilder.Length > 0) | ||||
|                 throw new Exception(stringBuilder.ToString()); | ||||
|         } | ||||
|     } | ||||
|  | ||||
|     private static void CreatePointerFile(int numberLength, string parentDirectory, List<string> matchingFiles) | ||||
|     { | ||||
| #nullable enable | ||||
|         string checkFile; | ||||
|         string writeFile; | ||||
|         string? directoryName; | ||||
|         int parentDirectoryLength = parentDirectory.Length; | ||||
|         foreach (string matchingFile in matchingFiles) | ||||
|         { | ||||
|             directoryName = Path.GetDirectoryName(matchingFile); | ||||
|             if (directoryName is null) | ||||
|                 continue; | ||||
|             checkFile = $"{matchingFile[0]}{directoryName.Substring(parentDirectoryLength + numberLength + 1)}"; | ||||
|             writeFile = Path.Combine(parentDirectory, $"{directoryName.Substring(parentDirectory.Length + 1, numberLength)}.txt"); | ||||
|             if (File.Exists(writeFile)) | ||||
|                 continue; | ||||
|             File.AppendAllLines(writeFile, new string[] { parentDirectory, matchingFile, directoryName, checkFile }); | ||||
|         } | ||||
| #nullable disable | ||||
|     } | ||||
|  | ||||
|     private Tuple<string, Test[], JsonElement[], List<FileInfo>> GetExtractResult(string reportFullPath, DateTime dateTime) | ||||
|     { | ||||
|         Tuple<string, Test[], JsonElement[], List<FileInfo>> results = new(string.Empty, null, null, new List<FileInfo>()); | ||||
|         Tuple<string, string[], string[]> pdsf = ProcessDataStandardFormat.GetLogisticsColumnsAndBody(reportFullPath); | ||||
|         _Logistics = new Logistics(reportFullPath, pdsf.Item1); | ||||
|         SetFileParameterLotIDToLogisticsMID(); | ||||
|         int numberLength = 2; | ||||
|         long ticks = dateTime.Ticks; | ||||
|         string parentParentDirectory = GetParentParent(reportFullPath); | ||||
|         List<string> searchDirectories = GetSearchDirectories(numberLength, parentParentDirectory); | ||||
|         List<string> matchingFiles = GetMatchingFiles(ticks, reportFullPath, searchDirectories); | ||||
|         if (matchingFiles.Count != searchDirectories.Count) | ||||
|             throw new Exception($"Didn't find all files after {_BreakAfterSeconds} second(s)!"); | ||||
|         try | ||||
|         { CreatePointerFile(numberLength, parentParentDirectory, matchingFiles); } | ||||
|         catch (Exception) { } | ||||
|         List<(string matchingFile, string checkFile)> collection = GetCollection(numberLength, parentParentDirectory, matchingFiles); | ||||
|         MoveCollection(dateTime, collection); | ||||
|         return results; | ||||
|         return results.AsReadOnly(); | ||||
|     } | ||||
|  | ||||
| } | ||||
| @ -9,7 +9,6 @@ using System.Collections.Generic; | ||||
| using System.Globalization; | ||||
| using System.IO; | ||||
| using System.Linq; | ||||
| using System.Text; | ||||
| using System.Text.Json; | ||||
|  | ||||
| namespace Adaptation.FileHandlers.OpenInsight; | ||||
| @ -18,10 +17,9 @@ public class FileRead : Shared.FileRead, IFileRead | ||||
| { | ||||
|  | ||||
|     private readonly string _IqsConnectionString; | ||||
|     private readonly string _OpenInsightFilePattern; | ||||
|     private readonly string _OpenInsightApiECDirectory; | ||||
|  | ||||
|     public FileRead(ISMTP smtp, Dictionary<string, string> fileParameter, string cellInstanceName, int? connectionCount, string cellInstanceConnectionName, FileConnectorConfiguration fileConnectorConfiguration, string equipmentTypeName, string parameterizedModelObjectDefinitionType, IList<ModelObjectParameterDefinition> modelObjectParameters, string equipmentDictionaryName, Dictionary<string, List<long>> dummyRuns, Dictionary<long, List<string>> staticRuns, bool useCyclicalForDescription, bool isEAFHosted) : | ||||
|     public FileRead(ISMTP smtp, Dictionary<string, string> fileParameter, string cellInstanceName, int? connectionCount, string cellInstanceConnectionName, FileConnectorConfiguration fileConnectorConfiguration, string equipmentTypeName, string parameterizedModelObjectDefinitionType, IList<ModelObjectParameterDefinition> modelObjectParameters, string equipmentDictionaryName, Dictionary<string, List<long>> dummyRuns, Dictionary<long, List<WS.Results>> staticRuns, bool useCyclicalForDescription, bool isEAFHosted) : | ||||
|         base(new Description(), false, smtp, fileParameter, cellInstanceName, connectionCount, cellInstanceConnectionName, fileConnectorConfiguration, equipmentTypeName, parameterizedModelObjectDefinitionType, modelObjectParameters, equipmentDictionaryName, dummyRuns, staticRuns, useCyclicalForDescription, isEAFHosted: connectionCount is null) | ||||
|     { | ||||
|         _MinFileLength = 10; | ||||
| @ -34,7 +32,6 @@ public class FileRead : Shared.FileRead, IFileRead | ||||
|         if (!_IsDuplicator) | ||||
|             throw new Exception(cellInstanceConnectionName); | ||||
|         _IqsConnectionString = GetPropertyValue(cellInstanceConnectionName, modelObjectParameters, "IQS.ConnectionString"); | ||||
|         _OpenInsightFilePattern = GetPropertyValue(cellInstanceConnectionName, modelObjectParameters, "OpenInsight.FilePattern"); | ||||
|         _OpenInsightApiECDirectory = GetPropertyValue(cellInstanceConnectionName, modelObjectParameters, "OpenInsight.Api.EC.Directory"); | ||||
|     } | ||||
|  | ||||
| @ -113,102 +110,61 @@ public class FileRead : Shared.FileRead, IFileRead | ||||
|         return results; | ||||
|     } | ||||
|  | ||||
|     internal static string GetLines(Logistics logistics, List<txt.Description> descriptions) | ||||
|     { | ||||
|         StringBuilder results = new(); | ||||
|         char del = '\t'; | ||||
|         txt.Description x = descriptions[0]; | ||||
|         _ = results.Append(x.UniqueId).Append(del). | ||||
|             Append(x.Run).Append(del). | ||||
|             Append(x.Date).Append(del). | ||||
|             Append(x.Lot).Append(del). | ||||
|             Append(x.Recipe).Append(del). | ||||
|             Append(x.Reactor).Append(del). | ||||
|             Append(x.RDS).Append(del). | ||||
|             Append(x.PSN).Append(del). | ||||
|             Append(x.Layer).Append(del). | ||||
|             Append(x.Zone).Append(del). | ||||
|             Append(logistics.MesEntity).Append(del). | ||||
|             Append(x.Employee).Append(del). | ||||
|             Append(x.Engineer).Append(del). | ||||
|             Append(x.DLRatio).Append(del). | ||||
|             Append(x.Temp).Append(del). | ||||
|             Append(x.AutoOptimizeGain).Append(del). | ||||
|             Append(x.AutoProbeHeightSet).Append(del). | ||||
|             Append(x.DataReject).Append(del). | ||||
|             Append(x.FileName).Append(del). | ||||
|             Append(x.Avg).Append(del). | ||||
|             Append(x.StdDev).Append(del). | ||||
|             Append(x.SemiRadial); | ||||
|         foreach (txt.Description description in descriptions) | ||||
|             _ = results.Append(del).Append(description.Pt). | ||||
|                         Append(del).Append(description.R). | ||||
|                         Append(del).Append(description.T). | ||||
|                         Append(del).Append(description.Rs). | ||||
|                         Append(del).Append(description.Merit); | ||||
|         return results.ToString(); | ||||
|     } | ||||
|  | ||||
|     private void SaveOpenInsightFile(string reportFullPath, DateTime dateTime, string logistics, List<txt.Description> descriptions, Test[] tests) | ||||
|     private void SaveOpenInsightFile(string reportFullPath, DateTime dateTime, List<RsM.Description> descriptions, Test[] tests) | ||||
|     { | ||||
|         string duplicateFile; | ||||
|         bool isDummyRun = false; | ||||
|         List<(Shared.Properties.IScopeInfo, string)> collection = new(); | ||||
|         string duplicateDirectory = Path.Combine(_FileConnectorConfiguration.SourceFileLocation, _CellInstanceName); | ||||
|         if (!Directory.Exists(duplicateDirectory)) | ||||
|             _ = Directory.CreateDirectory(duplicateDirectory); | ||||
|         string successDirectory = _FileConnectorConfiguration.AlternateTargetFolder; | ||||
|         if (!Directory.Exists(Path.Combine(duplicateDirectory, "1"))) | ||||
|         if (descriptions.Count == 0 || tests.Length == 0) | ||||
|             duplicateFile = Path.Combine(duplicateDirectory, Path.GetFileName(reportFullPath)); | ||||
|         else | ||||
|         { | ||||
|             string parentParent = GetParentParent(_FileConnectorConfiguration.SourceFileLocation); | ||||
|             if (parentParent.Contains(_CellInstanceName)) | ||||
|                 parentParent = Path.GetDirectoryName(parentParent); | ||||
|             duplicateDirectory = Path.Combine(parentParent, "Data"); | ||||
|             if (!Directory.Exists(duplicateDirectory)) | ||||
|                 _ = Directory.CreateDirectory(duplicateDirectory); | ||||
|         } | ||||
|         string duplicateFile = Path.Combine(duplicateDirectory, Path.GetFileName(reportFullPath)); | ||||
|         if (descriptions.Count != 0 && tests.Length != 0) | ||||
|         { | ||||
|             string lines = GetLines(_Logistics, descriptions); | ||||
|             if (!string.IsNullOrEmpty(lines)) | ||||
|             long? subgroupId; | ||||
|             string fileName = Path.GetFileName(reportFullPath); | ||||
|             long breakAfter = dateTime.AddSeconds(_BreakAfterSeconds).Ticks; | ||||
|             long preWait = _FileConnectorConfiguration?.FileHandleWaitTime is null ? dateTime.AddMilliseconds(1234).Ticks : dateTime.AddMilliseconds(_FileConnectorConfiguration.FileHandleWaitTime.Value).Ticks; | ||||
|             if (string.IsNullOrEmpty(descriptions[0].Reactor) || string.IsNullOrEmpty(descriptions[0].PSN)) | ||||
|                 subgroupId = null; | ||||
|             else | ||||
|                 (subgroupId, int? _, string _) = FromIQS.GetCommandText(_IqsConnectionString, _Logistics, descriptions[0], breakAfter, preWait); | ||||
|             if (_StaticRuns.TryGetValue(_Logistics.Sequence, out List<WS.Results> wsResults)) | ||||
|             { | ||||
|                 long? subGroupId; | ||||
|                 long breakAfter = dateTime.AddSeconds(_BreakAfterSeconds).Ticks; | ||||
|                 long preWait = _FileConnectorConfiguration?.FileHandleWaitTime is null ? dateTime.AddMilliseconds(1234).Ticks : dateTime.AddMilliseconds(_FileConnectorConfiguration.FileHandleWaitTime.Value).Ticks; | ||||
|                 if (string.IsNullOrEmpty(descriptions[0].Reactor) || string.IsNullOrEmpty(descriptions[0].PSN)) | ||||
|                     subGroupId = null; | ||||
|                 else | ||||
|                     (subGroupId, int? _, string _) = FromIQS.GetCommandText(_IqsConnectionString, _Logistics, descriptions[0], breakAfter, preWait); | ||||
|                 if (subGroupId is null) | ||||
|                     collection.Add(new(new ScopeInfo(tests[0], _OpenInsightFilePattern), lines)); | ||||
|                 else | ||||
|                     collection.Add(new(new ScopeInfo(tests[0], $"{subGroupId.Value} {_OpenInsightFilePattern}"), lines)); | ||||
|                 if (_StaticRuns.TryGetValue(_Logistics.Sequence, out List<string> values)) | ||||
|                 { | ||||
|                     if (values.Count != 1) | ||||
|                         throw new Exception($"{nameof(_StaticRuns)} {values.Count} != 1 {_Logistics.Sequence}!"); | ||||
|                     values[0] = $"{values[0]}|{subGroupId}"; | ||||
|                 } | ||||
|                 string weekOfYear = _Calendar.GetWeekOfYear(_Logistics.DateTimeFromSequence, CalendarWeekRule.FirstDay, DayOfWeek.Sunday).ToString("00"); | ||||
|                 FromIQS.Save(_OpenInsightApiECDirectory, _Logistics, reportFullPath, logistics, descriptions.First(), lines, subGroupId, weekOfYear); | ||||
|                 if (wsResults is null || wsResults.Count != 1) | ||||
|                     throw new NullReferenceException($"{nameof(wsResults)} {wsResults?.Count} != 1 {_Logistics.Sequence}!"); | ||||
|                 lock (_StaticRuns) | ||||
|                     wsResults[0] = WS.Results.Get(wsResults[0], subgroupId); | ||||
|             } | ||||
|             if (!fileName.StartsWith("Viewer")) | ||||
|                 duplicateFile = Path.Combine(duplicateDirectory, $"{subgroupId} {fileName}".TrimStart()); | ||||
|             else | ||||
|                 duplicateFile = Path.Combine(duplicateDirectory, $"{$"Viewer {subgroupId}".TrimEnd()} {fileName.Replace("Viewer", string.Empty)}"); | ||||
|             string weekOfYear = _Calendar.GetWeekOfYear(_Logistics.DateTimeFromSequence, CalendarWeekRule.FirstDay, DayOfWeek.Sunday).ToString("00"); | ||||
|             FromIQS.Save(_OpenInsightApiECDirectory, _Logistics, reportFullPath, descriptions.First(), subgroupId, weekOfYear); | ||||
|         } | ||||
|         if (_IsEAFHosted && _FileConnectorConfiguration.FileScanningIntervalInSeconds > 0) | ||||
|         { | ||||
|             File.Copy(reportFullPath, duplicateFile, overwrite: true); | ||||
|             WaitForFileConsumption(dateTime, descriptions, isDummyRun, successDirectory, duplicateDirectory, collection, duplicateFile); | ||||
|         } | ||||
|     } | ||||
|  | ||||
|     private Tuple<string, Test[], JsonElement[], List<FileInfo>> GetExtractResult(string reportFullPath, DateTime dateTime) | ||||
|     { | ||||
|         Tuple<string, Test[], JsonElement[], List<FileInfo>> results; | ||||
|         Tuple<string, string[], string[]> pdsf = ProcessDataStandardFormat.GetLogisticsColumnsAndBody(reportFullPath); | ||||
|         _Logistics = new Logistics(reportFullPath, pdsf.Item1); | ||||
|         string[] lines = File.ReadAllLines(reportFullPath); | ||||
|         ProcessDataStandardFormat processDataStandardFormat = ProcessDataStandardFormat.GetProcessDataStandardFormat(reportFullPath, lines); | ||||
|         _Logistics = new Logistics(reportFullPath, processDataStandardFormat); | ||||
|         SetFileParameterLotIDToLogisticsMID(); | ||||
|         JsonElement[] jsonElements = ProcessDataStandardFormat.GetArray(pdsf); | ||||
|         List<txt.Description> descriptions = txt.ProcessData.GetDescriptions(jsonElements); | ||||
|         JsonElement[] jsonElements = ProcessDataStandardFormat.GetArray(reportFullPath, lines, processDataStandardFormat); | ||||
|         List<RsM.Description> descriptions = RsM.ProcessData.GetDescriptions(jsonElements); | ||||
|         Test[] tests = (from l in descriptions select (Test)l.Test).ToArray(); | ||||
|         if (_IsEAFHosted && _FileConnectorConfiguration.FileScanningIntervalInSeconds > 0) | ||||
|             SaveOpenInsightFile(reportFullPath, dateTime, pdsf.Item1, descriptions, tests); | ||||
|         results = new Tuple<string, Test[], JsonElement[], List<FileInfo>>(pdsf.Item1, tests, jsonElements, new List<FileInfo>()); | ||||
|             SaveOpenInsightFile(reportFullPath, dateTime, descriptions, tests); | ||||
|         results = new Tuple<string, Test[], JsonElement[], List<FileInfo>>(string.Join(Environment.NewLine, processDataStandardFormat.Logistics), tests, jsonElements, new List<FileInfo>()); | ||||
|         return results; | ||||
|     } | ||||
|  | ||||
|  | ||||
| @ -128,7 +128,7 @@ public class FromIQS | ||||
|         return string.Join(Environment.NewLine, results); | ||||
|     } // cSpell:restore | ||||
|  | ||||
|     private static string GetCommandText(Logistics logistics, txt.Description description, string dateTime, long? subGroupId) | ||||
|     private static string GetCommandText(Logistics logistics, RsM.Description description, string dateTime, long? subGroupId) | ||||
|     { // cSpell:disable | ||||
|         List<string> results = new(); | ||||
|         results.Add(" select iq.ev_count, iq.cl_count, iq.sl_count, iq.se_sgrp, iq.se_sgtm, iq.se_tsno, iq.td_test, iq.pr_name, iq.jd_name, iq.pl_name, iq.pd_name, iq.td_name, iq.se_val "); | ||||
| @ -251,14 +251,14 @@ public class FromIQS | ||||
|         } | ||||
|     } | ||||
|  | ||||
|     internal static (long?, int?, string) GetCommandText(string connectionString, Logistics logistics, txt.Description description, long breakAfter, long preWait) | ||||
|     internal static (long?, int?, string) GetCommandText(string connectionString, Logistics logistics, RsM.Description description, long breakAfter, long preWait) | ||||
|     { | ||||
|         DateTime dateTime; | ||||
|         int? count = null; | ||||
|         string commandText; | ||||
|         long? result = null; | ||||
|         StringBuilder stringBuilder; | ||||
|         string dateFormat = txt.Description.GetDateFormat(); | ||||
|         string dateFormat = RsM.Description.GetDateFormat(); | ||||
|         if (DateTime.TryParseExact(description.Date, dateFormat, CultureInfo.InvariantCulture, DateTimeStyles.None, out DateTime dateTimeParsed)) | ||||
|             dateTime = dateTimeParsed; | ||||
|         else if (DateTime.TryParse(description.Date, CultureInfo.InvariantCulture, DateTimeStyles.None, out dateTimeParsed)) | ||||
| @ -325,77 +325,18 @@ public class FromIQS | ||||
|         return new(result, count, commandText); | ||||
|     } | ||||
|  | ||||
|     private static string GetJson(Logistics logistics, string logisticLines, txt.Description description) | ||||
|     internal static void Save(string openInsightApiECDirectory, Logistics logistics, string reportFullPath, RsM.Description description, long? subGroupId, string weekOfYear) | ||||
|     { | ||||
|         string result; | ||||
|         StringBuilder stringBuilder = new(); | ||||
|         var @object = new | ||||
|         { | ||||
|             description.MesEntity, | ||||
|             description.Employee, | ||||
|             description.Layer, | ||||
|             description.PSN, | ||||
|             description.RDS, | ||||
|             description.Reactor, | ||||
|             description.Recipe, | ||||
|             description.Zone, | ||||
|             logistics.DateTimeFromSequence.Ticks | ||||
|         }; | ||||
|         string[] pair; | ||||
|         string safeValue; | ||||
|         string[] segments; | ||||
|         string serializerValue; | ||||
|         foreach (string line in logisticLines.Split(new string[] { Environment.NewLine }, StringSplitOptions.None)) | ||||
|         { | ||||
|             segments = line.Split('\t'); | ||||
|             if (segments.Length < 2) | ||||
|                 continue; | ||||
|             segments = segments[1].Split(';'); | ||||
|             _ = stringBuilder.Append('{'); | ||||
|             foreach (string segment in segments) | ||||
|             { | ||||
|                 pair = segment.Split('='); | ||||
|                 if (pair.Length != 2 || pair[0].Length < 3) | ||||
|                     continue; | ||||
|                 serializerValue = JsonSerializer.Serialize(pair[1]); | ||||
|                 safeValue = serializerValue.Substring(1, serializerValue.Length - 2); | ||||
|                 _ = stringBuilder.Append('"').Append(pair[0].Substring(2)).Append('"').Append(':').Append('"').Append(safeValue).Append('"').Append(','); | ||||
|             } | ||||
|             if (stringBuilder.Length > 0) | ||||
|                 _ = stringBuilder.Remove(stringBuilder.Length - 1, 1); | ||||
|             _ = stringBuilder.Append('}').Append(','); | ||||
|         } | ||||
|         if (stringBuilder.Length > 0) | ||||
|             _ = stringBuilder.Remove(stringBuilder.Length - 1, 1); | ||||
|         _ = stringBuilder.Append(']').Append('}'); | ||||
|         _ = stringBuilder.Insert(0, ",\"Logistics\":["); | ||||
|         string json = JsonSerializer.Serialize(@object); | ||||
|         _ = stringBuilder.Insert(0, json.Substring(0, json.Length - 1)); | ||||
|         JsonElement? jsonElement = JsonSerializer.Deserialize<JsonElement>(stringBuilder.ToString()); | ||||
|         result = jsonElement is null ? "{}" : JsonSerializer.Serialize(jsonElement, new JsonSerializerOptions { WriteIndented = true }); | ||||
|         return result; | ||||
|     } | ||||
|  | ||||
|     internal static void Save(string openInsightApiECDirectory, Logistics logistics, string reportFullPath, string logisticLines, txt.Description description, string lines, long? subGroupId, string weekOfYear) | ||||
|     { | ||||
|         string checkFile; | ||||
|         string fileName = Path.GetFileName(reportFullPath); | ||||
|         string json = GetJson(logistics, logisticLines, description); | ||||
|         string? ecPathRoot = Path.GetPathRoot(openInsightApiECDirectory); | ||||
|         bool ecExists = ecPathRoot is not null && Directory.Exists(ecPathRoot); | ||||
|         string weekYear = $"{logistics.DateTimeFromSequence:yyyy}_Week_{weekOfYear}"; | ||||
|         string ecDirectory = Path.Combine(openInsightApiECDirectory, weekYear, $"-{description.PSN}", $"-{description.Reactor}", $"-{description.RDS}", $"-{subGroupId}"); | ||||
|         if (ecExists && !Directory.Exists(ecDirectory)) | ||||
|             _ = Directory.CreateDirectory(ecDirectory); | ||||
|         checkFile = Path.Combine(ecDirectory, fileName); | ||||
|         string checkFile = Path.Combine(ecDirectory, fileName); | ||||
|         if (ecExists && !File.Exists(checkFile)) | ||||
|             File.Copy(reportFullPath, checkFile); | ||||
|         checkFile = Path.Combine(ecDirectory, $"{logistics.DateTimeFromSequence.Ticks}.txt"); | ||||
|         if (ecExists && !File.Exists(checkFile)) | ||||
|             File.WriteAllText(checkFile, lines); | ||||
|         checkFile = Path.Combine(ecDirectory, $"{logistics.DateTimeFromSequence.Ticks}.json"); | ||||
|         if (ecExists && !File.Exists(checkFile)) | ||||
|             File.WriteAllText(checkFile, json); | ||||
|     } | ||||
|  | ||||
|     private static string GetCommandText(string[] iqsCopyValues) | ||||
|  | ||||
| @ -19,7 +19,7 @@ public class FileRead : Shared.FileRead, IFileRead | ||||
|     private readonly string _OpenInsightMetrologyViewerAPI; | ||||
|     private readonly string _OpenInsightMetrologyViewerFileShare; | ||||
|  | ||||
|     public FileRead(ISMTP smtp, Dictionary<string, string> fileParameter, string cellInstanceName, int? connectionCount, string cellInstanceConnectionName, FileConnectorConfiguration fileConnectorConfiguration, string equipmentTypeName, string parameterizedModelObjectDefinitionType, IList<ModelObjectParameterDefinition> modelObjectParameters, string equipmentDictionaryName, Dictionary<string, List<long>> dummyRuns, Dictionary<long, List<string>> staticRuns, bool useCyclicalForDescription, bool isEAFHosted) : | ||||
|     public FileRead(ISMTP smtp, Dictionary<string, string> fileParameter, string cellInstanceName, int? connectionCount, string cellInstanceConnectionName, FileConnectorConfiguration fileConnectorConfiguration, string equipmentTypeName, string parameterizedModelObjectDefinitionType, IList<ModelObjectParameterDefinition> modelObjectParameters, string equipmentDictionaryName, Dictionary<string, List<long>> dummyRuns, Dictionary<long, List<WS.Results>> staticRuns, bool useCyclicalForDescription, bool isEAFHosted) : | ||||
|         base(new Description(), false, smtp, fileParameter, cellInstanceName, connectionCount, cellInstanceConnectionName, fileConnectorConfiguration, equipmentTypeName, parameterizedModelObjectDefinitionType, modelObjectParameters, equipmentDictionaryName, dummyRuns, staticRuns, useCyclicalForDescription, isEAFHosted: connectionCount is null) | ||||
|     { | ||||
|         _MinFileLength = 10; | ||||
| @ -110,10 +110,10 @@ public class FileRead : Shared.FileRead, IFileRead | ||||
|         return results; | ||||
|     } | ||||
|  | ||||
|     private void SendData(string reportFullPath, DateTime dateTime, List<txt.Description> descriptions) | ||||
|     private void SendData(string reportFullPath, DateTime dateTime, JsonElement[] jsonElements, List<RsM.Description> descriptions) | ||||
|     { | ||||
|         string checkDirectory; | ||||
|         WSRequest wsRequest = new(this, _Logistics, descriptions); | ||||
|         WSRequest wsRequest = new(this, _Logistics, jsonElements, descriptions); | ||||
|         int weekOfYear = _Calendar.GetWeekOfYear(dateTime, CalendarWeekRule.FirstDay, DayOfWeek.Sunday); | ||||
|         string directory = Path.Combine(_OpenInsightMetrologyViewerFileShare, dateTime.Year.ToString(), $"WW{weekOfYear:00}"); | ||||
|         checkDirectory = Path.Combine(directory, _Logistics.Sequence.ToString()); | ||||
| @ -121,16 +121,16 @@ public class FileRead : Shared.FileRead, IFileRead | ||||
|             _ = Directory.CreateDirectory(checkDirectory); | ||||
|         File.Copy(reportFullPath, Path.Combine(checkDirectory, Path.GetFileName(reportFullPath)), overwrite: true); | ||||
|         (string jsonResults, WS.Results wsResults) = WS.SendData(_OpenInsightMetrologyViewerAPI, _Logistics.Sequence, directory, wsRequest); | ||||
|         if (!wsResults.Success) | ||||
|             throw new Exception(wsResults.ToString()); | ||||
|         _Log.Debug(wsResults.HeaderID); | ||||
|         if (wsResults.Success is null || !wsResults.Success.Value) | ||||
|             throw new Exception(jsonResults); | ||||
|         _Log.Debug(wsResults.HeaderId); | ||||
|         lock (_StaticRuns) | ||||
|         { | ||||
|             if (!_StaticRuns.ContainsKey(_Logistics.Sequence)) | ||||
|                 _StaticRuns.Add(_Logistics.Sequence, new()); | ||||
|             _StaticRuns[_Logistics.Sequence].Add(jsonResults); | ||||
|             _StaticRuns[_Logistics.Sequence].Add(wsResults); | ||||
|         } | ||||
|         checkDirectory = Path.Combine(directory, $"-{wsResults.HeaderID}"); | ||||
|         checkDirectory = Path.Combine(directory, $"-{wsResults.HeaderId}"); | ||||
|         if (!Directory.Exists(checkDirectory)) | ||||
|             _ = Directory.CreateDirectory(checkDirectory); | ||||
|         File.Copy(reportFullPath, Path.Combine(checkDirectory, Path.GetFileName(reportFullPath)), overwrite: true); | ||||
| @ -139,15 +139,16 @@ public class FileRead : Shared.FileRead, IFileRead | ||||
|     private Tuple<string, Test[], JsonElement[], List<FileInfo>> GetExtractResult(string reportFullPath, DateTime dateTime) | ||||
|     { | ||||
|         Tuple<string, Test[], JsonElement[], List<FileInfo>> results; | ||||
|         Tuple<string, string[], string[]> pdsf = ProcessDataStandardFormat.GetLogisticsColumnsAndBody(reportFullPath); | ||||
|         _Logistics = new Logistics(reportFullPath, pdsf.Item1); | ||||
|         string[] lines = File.ReadAllLines(reportFullPath); | ||||
|         ProcessDataStandardFormat processDataStandardFormat = ProcessDataStandardFormat.GetProcessDataStandardFormat(reportFullPath, lines); | ||||
|         _Logistics = new Logistics(reportFullPath, processDataStandardFormat); | ||||
|         SetFileParameterLotIDToLogisticsMID(); | ||||
|         JsonElement[] jsonElements = ProcessDataStandardFormat.GetArray(pdsf); | ||||
|         List<txt.Description> descriptions = txt.ProcessData.GetDescriptions(jsonElements); | ||||
|         JsonElement[] jsonElements = ProcessDataStandardFormat.GetArray(reportFullPath, lines, processDataStandardFormat); | ||||
|         List<RsM.Description> descriptions = RsM.ProcessData.GetDescriptions(jsonElements); | ||||
|         Test[] tests = (from l in descriptions select (Test)l.Test).ToArray(); | ||||
|         if (_IsEAFHosted && _FileConnectorConfiguration.FileScanningIntervalInSeconds > 0) | ||||
|             SendData(reportFullPath, dateTime, descriptions); | ||||
|         results = new Tuple<string, Test[], JsonElement[], List<FileInfo>>(pdsf.Item1, tests, jsonElements, new List<FileInfo>()); | ||||
|             SendData(reportFullPath, dateTime, jsonElements, descriptions); | ||||
|         results = new Tuple<string, Test[], JsonElement[], List<FileInfo>>(string.Join(Environment.NewLine, processDataStandardFormat.Logistics), tests, jsonElements, new List<FileInfo>()); | ||||
|         return results; | ||||
|     } | ||||
|  | ||||
|  | ||||
| @ -41,18 +41,18 @@ public class WSRequest | ||||
|     public string Temp { get; set; } | ||||
|     public string UniqueId { get; set; } | ||||
|     public string Zone { get; set; } | ||||
|     public List<txt.Detail> Details { get; protected set; } | ||||
|     public List<RsM.Detail> Details { get; protected set; } | ||||
|  | ||||
|     [Obsolete("For json")] public WSRequest() { } | ||||
|  | ||||
| #pragma warning disable IDE0060 | ||||
|     internal WSRequest(IFileRead fileRead, Logistics logistics, List<txt.Description> descriptions, string processDataStandardFormat = null) | ||||
|     internal WSRequest(IFileRead fileRead, Logistics logistics, JsonElement[] jsonElements, List<RsM.Description> descriptions, string processDataStandardFormat = null) | ||||
| #pragma warning restore IDE0060 | ||||
|     { | ||||
|         Id = -1; | ||||
|         CellName = logistics.MesEntity; | ||||
|         Details = new List<txt.Detail>(); | ||||
|         if (descriptions[0] is not txt.Description x) | ||||
|         Details = new List<RsM.Detail>(); | ||||
|         if (descriptions[0] is not RsM.Description x) | ||||
|             throw new Exception(); | ||||
|         //Header | ||||
|         { | ||||
| @ -62,12 +62,12 @@ public class WSRequest | ||||
|             DLRatio = x.DLRatio; | ||||
|             DataReject = x.DataReject; | ||||
|             Date = x.Date; | ||||
|             Op = x.Employee; | ||||
|             Op = x.Employee; // different name | ||||
|             Engineer = x.Engineer; | ||||
|             EquipId = logistics.MesEntity; | ||||
|             EquipId = logistics.MesEntity; // different name | ||||
|             FileName = x.FileName; | ||||
|             Layer = x.Layer; | ||||
|             LotId = x.Lot; | ||||
|             LotId = x.Lot; // different name | ||||
|             PSN = x.PSN; | ||||
|             RDS = x.RDS; | ||||
|             Reactor = x.Reactor; | ||||
| @ -75,15 +75,15 @@ public class WSRequest | ||||
|             ResistivitySpec = x.ResistivitySpec; | ||||
|             Run = x.Run; | ||||
|             SemiRadial = x.SemiRadial; | ||||
|             StDev = x.StdDev; | ||||
|             StDev = x.StdDev; // different name | ||||
|             Temp = x.Temp; | ||||
|             UniqueId = x.UniqueId; | ||||
|             Zone = x.Zone; | ||||
|         } | ||||
|         txt.Detail detail; | ||||
|         foreach (txt.Description description in descriptions) | ||||
|         RsM.Detail detail; | ||||
|         foreach (RsM.Description description in descriptions) | ||||
|         { | ||||
|             detail = new txt.Detail | ||||
|             detail = new RsM.Detail | ||||
|             { | ||||
|                 HeaderUniqueId = description.HeaderUniqueId, | ||||
|                 Merit = description.Merit, | ||||
| @ -96,35 +96,40 @@ public class WSRequest | ||||
|             Details.Add(detail); | ||||
|         } | ||||
|         Date ??= logistics.DateTimeFromSequence.ToString(); | ||||
|         if (UniqueId is null && Details.Count != 0) | ||||
|             UniqueId = Details[0].HeaderUniqueId; | ||||
|         UniqueId = $"{logistics.JobID}_{logistics.MID}_{logistics.DateTimeFromSequence:yyyyMMddHHmmssffff}"; | ||||
|         for (int i = 0; i < Details.Count; i++) | ||||
|         { | ||||
|             Details[i].HeaderUniqueId = UniqueId; | ||||
|             Details[i].UniqueId = $"{logistics.JobID}_{logistics.MID}_{logistics.DateTimeFromSequence:yyyyMMddHHmmssffff}_Item-{i + 1}"; | ||||
|         } | ||||
|         string onlyWSRequest = string.Empty; | ||||
|         FilePath = onlyWSRequest; | ||||
|     } | ||||
|  | ||||
|     internal static long GetHeaderId(IFileRead fileRead, Logistics logistics, string openInsightMetrologyViewerAPI, string openInsightMetrologyViewerFileShare, int weekOfYear, string json, List<txt.Description> descriptions) | ||||
|     internal static long GetHeaderId(IFileRead fileRead, Logistics logistics, string openInsightMetrologyViewerAPI, string openInsightMetrologyViewerFileShare, int weekOfYear, WS.Results results, JsonElement[] jsonElements, List<RsM.Description> descriptions) | ||||
|     { | ||||
|         long result; | ||||
|         if (string.IsNullOrEmpty(json)) | ||||
|         if (results is not null && results.HeaderId is not null) | ||||
|             result = results.HeaderId.Value; | ||||
|         else | ||||
|         { | ||||
|             WSRequest wsRequest = new(fileRead, logistics, descriptions); | ||||
|             WSRequest wsRequest = new(fileRead, logistics, jsonElements, descriptions); | ||||
|             string directory = Path.Combine(openInsightMetrologyViewerFileShare, logistics.DateTimeFromSequence.Year.ToString(), $"WW{weekOfYear:00}"); | ||||
|             (json, WS.Results wsResults) = WS.SendData(openInsightMetrologyViewerAPI, logistics.Sequence, directory, wsRequest); | ||||
|             if (!wsResults.Success) | ||||
|             (_, WS.Results wsResults) = WS.SendData(openInsightMetrologyViewerAPI, logistics.Sequence, directory, wsRequest); | ||||
|             if (wsResults.Success is null || !wsResults.Success.Value) | ||||
|                 throw new Exception(wsResults.ToString()); | ||||
|             result = wsResults.HeaderId.Value; | ||||
|         } | ||||
|         WS.Results metrologyWSRequest = JsonSerializer.Deserialize<WS.Results>(json, new JsonSerializerOptions { PropertyNameCaseInsensitive = true }); | ||||
|         result = metrologyWSRequest.HeaderID; | ||||
|         return result; | ||||
|     } | ||||
|  | ||||
| #pragma warning disable IDE0060 | ||||
|     internal static void PostOpenInsightMetrologyViewerAttachments(IFileRead fileRead, Logistics logistics, string openInsightMetrologyViewerAPI, List<txt.Description> descriptions, string matchDirectory, string subGroupId, long headerId, string headerIdDirectory) | ||||
|     internal static void PostOpenInsightMetrologyViewerAttachments(IFileRead fileRead, Logistics logistics, string openInsightMetrologyViewerAPI, List<RsM.Description> descriptions, string matchDirectory, WS.Results results, string headerIdDirectory) | ||||
| #pragma warning restore IDE0060 | ||||
|     { | ||||
|         string[] txtFiles = Directory.GetFiles(matchDirectory, "*.txt", SearchOption.TopDirectoryOnly); | ||||
|         if (txtFiles.Length != 1) | ||||
|             throw new Exception($"Invalid source file count for <{headerId}>!"); | ||||
|             throw new Exception($"Invalid source file count for <{results.HeaderId}>!"); | ||||
|         List<string> pdfFiles = new(); | ||||
|         pdfFiles.AddRange(Directory.GetFiles(matchDirectory, "*.pdf_old", SearchOption.TopDirectoryOnly)); | ||||
|         foreach (string pdfFile in pdfFiles) | ||||
| @ -138,7 +143,7 @@ public class WSRequest | ||||
|             throw new Exception("Invalid *.pdf file count!"); | ||||
|         List<WS.Attachment> headerAttachments = new() | ||||
|         { | ||||
|             new WS.Attachment(subGroupId, headerId, headerIdDirectory, descriptions[0].HeaderUniqueId, "Data.pdf", pdfFiles[0]) | ||||
|             new WS.Attachment(results, headerIdDirectory, $"{logistics.JobID}_{logistics.MID}_{logistics.DateTimeFromSequence:yyyyMMddHHmmssffff}", "Data.pdf", pdfFiles[0]) | ||||
|         }; | ||||
|         WS.AttachFiles(openInsightMetrologyViewerAPI, headerAttachments, dataAttachments: null); | ||||
|     } | ||||
|  | ||||
| @ -18,7 +18,7 @@ public class FileRead : Shared.FileRead, IFileRead | ||||
|     private readonly string _OpenInsightMetrologyViewerAPI; | ||||
|     private readonly string _OpenInsightMetrologyViewerFileShare; | ||||
|  | ||||
|     public FileRead(ISMTP smtp, Dictionary<string, string> fileParameter, string cellInstanceName, int? connectionCount, string cellInstanceConnectionName, FileConnectorConfiguration fileConnectorConfiguration, string equipmentTypeName, string parameterizedModelObjectDefinitionType, IList<ModelObjectParameterDefinition> modelObjectParameters, string equipmentDictionaryName, Dictionary<string, List<long>> dummyRuns, Dictionary<long, List<string>> staticRuns, bool useCyclicalForDescription, bool isEAFHosted) : | ||||
|     public FileRead(ISMTP smtp, Dictionary<string, string> fileParameter, string cellInstanceName, int? connectionCount, string cellInstanceConnectionName, FileConnectorConfiguration fileConnectorConfiguration, string equipmentTypeName, string parameterizedModelObjectDefinitionType, IList<ModelObjectParameterDefinition> modelObjectParameters, string equipmentDictionaryName, Dictionary<string, List<long>> dummyRuns, Dictionary<long, List<Shared.Metrology.WS.Results>> staticRuns, bool useCyclicalForDescription, bool isEAFHosted) : | ||||
|         base(new Description(), false, smtp, fileParameter, cellInstanceName, connectionCount, cellInstanceConnectionName, fileConnectorConfiguration, equipmentTypeName, parameterizedModelObjectDefinitionType, modelObjectParameters, equipmentDictionaryName, dummyRuns, staticRuns, useCyclicalForDescription, isEAFHosted: connectionCount is null) | ||||
|     { | ||||
|         _MinFileLength = 10; | ||||
| @ -135,32 +135,27 @@ public class FileRead : Shared.FileRead, IFileRead | ||||
|         return result; | ||||
|     } | ||||
|  | ||||
|     private void PostOpenInsightMetrologyViewerAttachments(List<txt.Description> descriptions) | ||||
|     private void PostOpenInsightMetrologyViewerAttachments(JsonElement[] jsonElements, List<RsM.Description> descriptions) | ||||
|     { | ||||
|         string? json; | ||||
|         string? subGroupId; | ||||
|         Shared.Metrology.WS.Results? results; | ||||
|         string jobIdDirectory = Path.Combine(Path.GetDirectoryName(_FileConnectorConfiguration.AlternateTargetFolder) ?? throw new Exception(), _Logistics.JobID); | ||||
|         if (!Directory.Exists(jobIdDirectory)) | ||||
|             _ = Directory.CreateDirectory(jobIdDirectory); | ||||
|         string[] matchDirectories = GetInProcessDirectory(jobIdDirectory); | ||||
|         if (!_StaticRuns.TryGetValue(_Logistics.Sequence, out List<string>? values)) | ||||
|             (json, subGroupId) = (null, null); | ||||
|         if (!_StaticRuns.TryGetValue(_Logistics.Sequence, out List<Shared.Metrology.WS.Results>? wsResults)) | ||||
|             results = null; | ||||
|         else | ||||
|         { | ||||
|             if (values.Count != 1) | ||||
|                 throw new Exception($"{nameof(_StaticRuns)} {values.Count} != 1 {_Logistics.Sequence}!"); | ||||
|             string[] segments = values[0].Split(new string[] { "|" }, StringSplitOptions.None); | ||||
|             json = segments[0]; | ||||
|             subGroupId = segments.Length > 1 ? segments[1] : null; | ||||
|             lock (_StaticRuns) | ||||
|                 _ = _StaticRuns.Remove(_Logistics.Sequence); | ||||
|             if (wsResults is null || wsResults.Count != 1) | ||||
|                 throw new NullReferenceException($"{nameof(wsResults)} {wsResults?.Count} != 1 {_Logistics.Sequence}!"); | ||||
|             results = wsResults[0]; | ||||
|         } | ||||
|         int weekOfYear = _Calendar.GetWeekOfYear(_Logistics.DateTimeFromSequence, CalendarWeekRule.FirstDay, DayOfWeek.Sunday); | ||||
|         long headerId = !_IsEAFHosted ? -1 : OpenInsightMetrologyViewer.WSRequest.GetHeaderId(this, _Logistics, _OpenInsightMetrologyViewerAPI, _OpenInsightMetrologyViewerFileShare, weekOfYear, json, descriptions); | ||||
|         long headerId = !_IsEAFHosted ? -1 : OpenInsightMetrologyViewer.WSRequest.GetHeaderId(this, _Logistics, _OpenInsightMetrologyViewerAPI, _OpenInsightMetrologyViewerFileShare, weekOfYear, results, jsonElements, descriptions); | ||||
|         string? headerIdDirectory = GetHeaderIdDirectory(headerId); | ||||
|         if (string.IsNullOrEmpty(headerIdDirectory)) | ||||
|             throw new Exception($"Didn't find header id directory <{headerId}>"); | ||||
|         OpenInsightMetrologyViewer.WSRequest.PostOpenInsightMetrologyViewerAttachments(this, _Logistics, _OpenInsightMetrologyViewerAPI, descriptions, matchDirectories[0], subGroupId, headerId, headerIdDirectory); | ||||
|         OpenInsightMetrologyViewer.WSRequest.PostOpenInsightMetrologyViewerAttachments(this, _Logistics, _OpenInsightMetrologyViewerAPI, descriptions, matchDirectories[0], results, headerIdDirectory); | ||||
|     } | ||||
|  | ||||
|     private Tuple<string, Test[], JsonElement[], List<FileInfo>> GetExtractResult(string reportFullPath, DateTime dateTime) | ||||
| @ -168,15 +163,16 @@ public class FileRead : Shared.FileRead, IFileRead | ||||
|         if (dateTime == DateTime.MinValue) | ||||
|             throw new ArgumentNullException(nameof(dateTime)); | ||||
|         Tuple<string, Test[], JsonElement[], List<FileInfo>> results; | ||||
|         Tuple<string, string[], string[]> pdsf = ProcessDataStandardFormat.GetLogisticsColumnsAndBody(reportFullPath); | ||||
|         _Logistics = new Logistics(reportFullPath, pdsf.Item1); | ||||
|         string[] lines = File.ReadAllLines(reportFullPath); | ||||
|         ProcessDataStandardFormat processDataStandardFormat = ProcessDataStandardFormat.GetProcessDataStandardFormat(reportFullPath, lines); | ||||
|         _Logistics = new Logistics(reportFullPath, processDataStandardFormat); | ||||
|         SetFileParameterLotIDToLogisticsMID(); | ||||
|         JsonElement[] jsonElements = ProcessDataStandardFormat.GetArray(pdsf); | ||||
|         List<txt.Description> descriptions = txt.ProcessData.GetDescriptions(jsonElements); | ||||
|         JsonElement[] jsonElements = ProcessDataStandardFormat.GetArray(reportFullPath, lines, processDataStandardFormat); | ||||
|         List<RsM.Description> descriptions = RsM.ProcessData.GetDescriptions(jsonElements); | ||||
|         Test[] tests = (from l in descriptions select (Test)l.Test).ToArray(); | ||||
|         if (_IsEAFHosted && _FileConnectorConfiguration.FileScanningIntervalInSeconds > 0) | ||||
|             PostOpenInsightMetrologyViewerAttachments(descriptions); | ||||
|         results = new Tuple<string, Test[], JsonElement[], List<FileInfo>>(pdsf.Item1, tests, jsonElements, new List<FileInfo>()); | ||||
|             PostOpenInsightMetrologyViewerAttachments(jsonElements, descriptions); | ||||
|         results = new Tuple<string, Test[], JsonElement[], List<FileInfo>>(string.Join(Environment.NewLine, processDataStandardFormat.Logistics), tests, jsonElements, new List<FileInfo>()); | ||||
|         return results; | ||||
|     } | ||||
|  | ||||
|  | ||||
| @ -17,7 +17,7 @@ public class FileRead : Shared.FileRead, IFileRead | ||||
|     private readonly string _JobIdParentDirectory; | ||||
|     private readonly string _JobIdProcessParentDirectory; | ||||
|  | ||||
|     public FileRead(ISMTP smtp, Dictionary<string, string> fileParameter, string cellInstanceName, int? connectionCount, string cellInstanceConnectionName, FileConnectorConfiguration fileConnectorConfiguration, string equipmentTypeName, string parameterizedModelObjectDefinitionType, IList<ModelObjectParameterDefinition> modelObjectParameters, string equipmentDictionaryName, Dictionary<string, List<long>> dummyRuns, Dictionary<long, List<string>> staticRuns, bool useCyclicalForDescription, bool isEAFHosted) : | ||||
|     public FileRead(ISMTP smtp, Dictionary<string, string> fileParameter, string cellInstanceName, int? connectionCount, string cellInstanceConnectionName, FileConnectorConfiguration fileConnectorConfiguration, string equipmentTypeName, string parameterizedModelObjectDefinitionType, IList<ModelObjectParameterDefinition> modelObjectParameters, string equipmentDictionaryName, Dictionary<string, List<long>> dummyRuns, Dictionary<long, List<Shared.Metrology.WS.Results>> staticRuns, bool useCyclicalForDescription, bool isEAFHosted) : | ||||
|         base(new Description(), false, smtp, fileParameter, cellInstanceName, connectionCount, cellInstanceConnectionName, fileConnectorConfiguration, equipmentTypeName, parameterizedModelObjectDefinitionType, modelObjectParameters, equipmentDictionaryName, dummyRuns, staticRuns, useCyclicalForDescription, isEAFHosted: connectionCount is null) | ||||
|     { | ||||
|         _MinFileLength = 10; | ||||
| @ -108,7 +108,7 @@ public class FileRead : Shared.FileRead, IFileRead | ||||
|         return results; | ||||
|     } | ||||
|  | ||||
|     private void DirectoryMove(string reportFullPath, DateTime dateTime, List<txt.Description> descriptions) | ||||
|     private void DirectoryMove(string reportFullPath, DateTime dateTime, JsonElement[] jsonElements, List<RsM.Description> descriptions) | ||||
|     { | ||||
|         if (dateTime == DateTime.MinValue) | ||||
|             throw new ArgumentNullException(nameof(dateTime)); | ||||
| @ -122,40 +122,68 @@ public class FileRead : Shared.FileRead, IFileRead | ||||
|             throw new Exception("Didn't find directory by logistics sequence"); | ||||
|         if (fileInfo.Exists && fileInfo.LastWriteTime < fileInfo.CreationTime) | ||||
|             File.SetLastWriteTime(reportFullPath, fileInfo.CreationTime); | ||||
|         OpenInsightMetrologyViewer.WSRequest wsRequest = new(this, _Logistics, descriptions); | ||||
|         OpenInsightMetrologyViewer.WSRequest wsRequest = new(this, _Logistics, jsonElements, descriptions); | ||||
|         JsonSerializerOptions jsonSerializerOptions = new() { WriteIndented = true }; | ||||
|         string json = JsonSerializer.Serialize(wsRequest, wsRequest.GetType(), jsonSerializerOptions); | ||||
|         string directoryName = $"{Path.GetFileName(matchDirectories[0]).Split(new string[] { logisticsSequence }, StringSplitOptions.None)[0]}{_Logistics.DateTimeFromSequence:yyyy-MM-dd_hh;mm_tt_}{DateTime.Now.Ticks - _Logistics.Sequence}"; | ||||
|         string destinationJobIdDirectory = Path.Combine(_JobIdProcessParentDirectory, _Logistics.JobID, directoryName); | ||||
|         string sequenceDirectory = Path.Combine(destinationJobIdDirectory, logisticsSequence); | ||||
|         string jsonFileName = Path.Combine(sequenceDirectory, $"{Path.GetFileNameWithoutExtension(reportFullPath)}.json"); | ||||
|         MoveMatchingFile(jobIdDirectory, matchDirectories[0]); | ||||
|         Directory.Move(matchDirectories[0], destinationJobIdDirectory); | ||||
|         if (!Directory.Exists(sequenceDirectory)) | ||||
|             _ = Directory.CreateDirectory(sequenceDirectory); | ||||
|         File.Copy(reportFullPath, Path.Combine(sequenceDirectory, Path.GetFileName(reportFullPath)), overwrite: true); | ||||
|         File.WriteAllText(jsonFileName, json); | ||||
|         lock (_StaticRuns) | ||||
|             _ = _StaticRuns.Remove(_Logistics.Sequence); | ||||
|     } | ||||
|  | ||||
|     private static void MoveMatchingFile(string jobIdDirectory, string matchDirectory) | ||||
|     { | ||||
|         string checkFile; | ||||
|         string jobIdDirectoryFileName; | ||||
|         string matchDirectoryFileName; | ||||
|         string[] jobIdDirectoryFiles = Directory.GetFiles(jobIdDirectory, "*", SearchOption.TopDirectoryOnly); | ||||
|         string[] matchDirectoryFiles = Directory.GetFiles(matchDirectory, "*", SearchOption.TopDirectoryOnly); | ||||
|         foreach (string jobIdDirectoryFile in jobIdDirectoryFiles) | ||||
|         { | ||||
|             jobIdDirectoryFileName = Path.GetFileName(jobIdDirectoryFile); | ||||
|             foreach (string matchDirectoryFile in matchDirectoryFiles) | ||||
|             { | ||||
|                 matchDirectoryFileName = Path.GetFileName(matchDirectoryFile); | ||||
|                 if (jobIdDirectoryFileName.StartsWith(matchDirectoryFileName)) | ||||
|                 { | ||||
|                     checkFile = Path.Combine(matchDirectory, jobIdDirectoryFileName); | ||||
|                     if (File.Exists(checkFile)) | ||||
|                         continue; | ||||
|                     File.Move(jobIdDirectoryFile, checkFile); | ||||
|                 } | ||||
|             } | ||||
|         } | ||||
|     } | ||||
|  | ||||
|     private Tuple<string, Test[], JsonElement[], List<FileInfo>> GetExtractResult(string reportFullPath, DateTime dateTime) | ||||
|     { | ||||
|         Tuple<string, Test[], JsonElement[], List<FileInfo>> results; | ||||
|         Tuple<string, string[], string[]> pdsf = ProcessDataStandardFormat.GetLogisticsColumnsAndBody(reportFullPath); | ||||
|         _Logistics = new Logistics(reportFullPath, pdsf.Item1); | ||||
|         string[] lines = File.ReadAllLines(reportFullPath); | ||||
|         ProcessDataStandardFormat processDataStandardFormat = ProcessDataStandardFormat.GetProcessDataStandardFormat(reportFullPath, lines); | ||||
|         _Logistics = new Logistics(reportFullPath, processDataStandardFormat); | ||||
|         SetFileParameterLotIDToLogisticsMID(); | ||||
|         JsonElement[] jsonElements = ProcessDataStandardFormat.GetArray(pdsf); | ||||
|         List<txt.Description> descriptions = txt.ProcessData.GetDescriptions(jsonElements); | ||||
|         JsonElement[] jsonElements = ProcessDataStandardFormat.GetArray(reportFullPath, lines, processDataStandardFormat); | ||||
|         List<RsM.Description> descriptions = RsM.ProcessData.GetDescriptions(jsonElements); | ||||
|         Test[] tests = (from l in descriptions select (Test)l.Test).ToArray(); | ||||
|         results = new Tuple<string, Test[], JsonElement[], List<FileInfo>>(pdsf.Item1, tests, jsonElements, new List<FileInfo>()); | ||||
|         results = new Tuple<string, Test[], JsonElement[], List<FileInfo>>(string.Join(Environment.NewLine, processDataStandardFormat.Logistics), tests, jsonElements, new List<FileInfo>()); | ||||
|         if (_IsEAFHosted && _FileConnectorConfiguration.FileScanningIntervalInSeconds > 0) | ||||
|             DirectoryMove(reportFullPath, dateTime, descriptions); | ||||
|             DirectoryMove(reportFullPath, dateTime, jsonElements, descriptions); | ||||
|         else if (!_IsEAFHosted) | ||||
|         { | ||||
|             OpenInsightMetrologyViewer.WSRequest wsRequest = new(this, _Logistics, descriptions); | ||||
|             OpenInsightMetrologyViewer.WSRequest wsRequest = new(this, _Logistics, jsonElements, descriptions); | ||||
|             JsonSerializerOptions jsonSerializerOptions = new() { WriteIndented = true }; | ||||
|             string json = JsonSerializer.Serialize(wsRequest, wsRequest.GetType(), jsonSerializerOptions); | ||||
|             string check = JsonSerializer.Serialize(wsRequest, wsRequest.GetType(), jsonSerializerOptions); | ||||
|             string jsonFileName = Path.ChangeExtension(reportFullPath, ".json"); | ||||
|             string historicalText = File.ReadAllText(jsonFileName); | ||||
|             if (json != historicalText) | ||||
|             if (check != historicalText) | ||||
|                 throw new Exception("File doesn't match historical!"); | ||||
|         } | ||||
|         return results; | ||||
|  | ||||
| @ -1,135 +0,0 @@ | ||||
| using Adaptation.Shared; | ||||
| using System; | ||||
| using System.Collections.Generic; | ||||
| using System.Collections.ObjectModel; | ||||
| using System.IO; | ||||
| using System.Linq; | ||||
| using System.Text.Json; | ||||
| using System.Text.Json.Serialization; | ||||
|  | ||||
| namespace Adaptation.FileHandlers.RsM; | ||||
|  | ||||
| #nullable enable | ||||
|  | ||||
| internal class Complete | ||||
| { | ||||
|     public Complete(Line1 line1, Line2 line2, Line3 line3, Line4 line4, Line4B line4B, Line5 line5, Line6 line6, Line7 line7, Line8 line8, Line9 line9, Line10 line10, Line11 line11, Line12 line12, Line13 line13, Point[] points) | ||||
|     { | ||||
|         Line1 = line1; | ||||
|         Line2 = line2; | ||||
|         Line3 = line3; | ||||
|         Line4 = line4; | ||||
|         Line4B = line4B; | ||||
|         Line5 = line5; | ||||
|         Line6 = line6; | ||||
|         Line7 = line7; | ||||
|         Line8 = line8; | ||||
|         Line9 = line9; | ||||
|         Line10 = line10; | ||||
|         Line11 = line11; | ||||
|         Line12 = line12; | ||||
|         Line13 = line13; | ||||
|         Points = points; | ||||
|     } | ||||
|  | ||||
|     public Line1 Line1 { get; } | ||||
|     public Line2 Line2 { get; } | ||||
|     public Line3 Line3 { get; } | ||||
|     public Line4 Line4 { get; } | ||||
|     public Line4B Line4B { get; } | ||||
|     public Line5 Line5 { get; } | ||||
|     public Line6 Line6 { get; } | ||||
|     public Line7 Line7 { get; } | ||||
|     public Line8 Line8 { get; } | ||||
|     public Line9 Line9 { get; } | ||||
|     public Line10 Line10 { get; } | ||||
|     public Line11 Line11 { get; } | ||||
|     public Line12 Line12 { get; } | ||||
|     public Line13 Line13 { get; } | ||||
|     public Point[] Points { get; } | ||||
|  | ||||
|     internal static ReadOnlyCollection<string> GetCollection(string[] segments) | ||||
|     { | ||||
|         List<string> results = new(); | ||||
|         foreach (string segment in segments) | ||||
|         { | ||||
|             if (segment[0] == ',') | ||||
|                 break; | ||||
|             results.Add(segment); | ||||
|         } | ||||
|         return new(results); | ||||
|     } | ||||
|  | ||||
|     internal static Complete? Get(Logistics logistics, List<FileInfo> fileInfoCollection) | ||||
|     { | ||||
|         Complete? result; | ||||
|         int take = 14; | ||||
|         string[] lines = File.ReadAllLines(logistics.ReportFullPath); | ||||
|         ReadOnlyCollection<string> collection = new(lines); | ||||
|         if (collection.Count > take) | ||||
|             result = null; | ||||
|         else | ||||
|         { | ||||
|             if (collection.Count < take) | ||||
|                 result = null; | ||||
|             else | ||||
|             { | ||||
|                 string[] separator = new string[] { " ", "\t" }; | ||||
|                 // <Title> | ||||
|                 Line1 line1 = Line1.Get(collection[0].Split(separator, StringSplitOptions.RemoveEmptyEntries)); | ||||
|                 // <FileName, Proj,Rcpe, LotID,WfrID, Is_TF_DataFile> | ||||
|                 Line2 line2 = Line2.Get(collection[1].Split(separator, StringSplitOptions.RemoveEmptyEntries)); | ||||
|                 // <Directory> | ||||
|                 Line3 line3 = Line3.Get(collection[2].Split(separator, StringSplitOptions.RemoveEmptyEntries)); | ||||
|                 // <DateTime,Temp,TCR%,N|P> | ||||
|                 Line4 line4 = Line4.Get(collection[3].Split(separator, StringSplitOptions.RemoveEmptyEntries)); | ||||
|                 // <Avg,Dev,Min,Max> | ||||
|                 Line4B? line4B = Line4B.Get(collection[3].Split(new string[] { ">" }, StringSplitOptions.RemoveEmptyEntries)); | ||||
|                 if (line4B is null) | ||||
|                     result = null; | ||||
|                 else | ||||
|                 { | ||||
|                     // <Operator, Epuipment> | ||||
|                     Line5 line5 = Line5.Get(collection[4].Split(separator, StringSplitOptions.RemoveEmptyEntries)); | ||||
|                     // <Engineer> | ||||
|                     Line6 line6 = Line6.Get(collection[5].Split(separator, StringSplitOptions.RemoveEmptyEntries)); | ||||
|                     // <AreaOrDiamScan, WaferShape, dNBand,  TemplateFile,  xsize,ysize, CalibFactor, MsmtMode,  DataType,  DataUnit> | ||||
|                     Line7 line7 = Line7.Get(collection[6].Split(separator, StringSplitOptions.RemoveEmptyEntries)); | ||||
|                     // <NumProbePoints, SingleOrDualProbeConfig, #ActPrbPts,  Rsens,IdrvMx,VinGain, DataRejectSigma, MeritThreshold, PrbChg#, PrbName> | ||||
|                     Line8 line8 = Line8.Get(collection[7].Split(separator, StringSplitOptions.RemoveEmptyEntries)); | ||||
|                     // <WaferSize,EdgeEx, x,yll, x,yur, #x,y, CutCorners> | ||||
|                     Line9 line9 = Line9.Get(collection[8].Split(separator, StringSplitOptions.RemoveEmptyEntries)); | ||||
|                     // <Diam: ThScan Start End Step> | ||||
|                     Line10 line10 = Line10.Get(collection[9].Split(separator, StringSplitOptions.RemoveEmptyEntries)); | ||||
|                     // <FlatOrNotch FollowMajorFlat AutoOrManualLoad RangeOrIndvdual PauseAfterEveryRun, AutoPrint,Plot, BulkSmplThk & Unit> | ||||
|                     Line11 line11 = Line11.Get(collection[10].Split(separator, StringSplitOptions.RemoveEmptyEntries)); | ||||
|                     // <RangeFrom, RangeTo> | ||||
|                     Line12 line12 = Line12.Get(collection[11].Split(separator, StringSplitOptions.RemoveEmptyEntries)); | ||||
|                     // <CassSlotSelected> | ||||
|                     Line13 line13 = Line13.Get(collection[12].Split(separator, StringSplitOptions.RemoveEmptyEntries)); | ||||
|                     // <R,Th,Data, Rs,RsA,RsB, #Smpl, x,y, Irng,Vrng, ChiSq,merit/GOF, DataIntegrity> | ||||
|                     ReadOnlyCollection<Point> points = Point.Get(take, collection, separator); | ||||
|                     if (points.Count == 0) | ||||
|                         result = null; | ||||
|                     else | ||||
|                     { | ||||
|                         result = new(line1, line2, line3, line4, line4B, line5, line6, line7, line8, line9, line10, line11, line12, line13, points.ToArray()); | ||||
|                         FileInfo fileInfo = new($"{logistics.ReportFullPath}.json"); | ||||
|                         string json = JsonSerializer.Serialize(result, CompleteSourceGenerationContext.Default.Complete); | ||||
|                         File.WriteAllText(fileInfo.FullName, json); | ||||
|                         File.SetLastWriteTime(fileInfo.FullName, logistics.DateTimeFromSequence); | ||||
|                         fileInfoCollection.Add(fileInfo); | ||||
|                     } | ||||
|                 } | ||||
|             } | ||||
|         } | ||||
|         return result; | ||||
|     } | ||||
|  | ||||
| } | ||||
|  | ||||
| [JsonSourceGenerationOptions(WriteIndented = true)] | ||||
| [JsonSerializable(typeof(Complete))] | ||||
| internal partial class CompleteSourceGenerationContext : JsonSerializerContext | ||||
| { | ||||
| } | ||||
| @ -4,59 +4,60 @@ using System; | ||||
| using System.Collections.Generic; | ||||
| using System.Linq; | ||||
| using System.Text.Json; | ||||
| using System.Text.Json.Serialization; | ||||
|  | ||||
| namespace Adaptation.FileHandlers.RsM; | ||||
|  | ||||
| public class Description : IDescription, Shared.Properties.IDescription | ||||
| { | ||||
|  | ||||
|     public int Test { get; set; } | ||||
|     public int Count { get; set; } | ||||
|     public int Index { get; set; } | ||||
|     [JsonPropertyName("EventId")] public int Test { get; set; } | ||||
|     [JsonPropertyName("Count")] public int Count { get; set; } | ||||
|     [JsonPropertyName("Index")] public int Index { get; set; } | ||||
|     // | ||||
|     public string EventName { get; set; } | ||||
|     public string NullData { get; set; } | ||||
|     public string JobID { get; set; } | ||||
|     public string Sequence { get; set; } | ||||
|     public string MesEntity { get; set; } | ||||
|     [JsonPropertyName("MesEntity")] public string MesEntity { get; set; } | ||||
|     public string ReportFullPath { get; set; } | ||||
|     public string ProcessJobID { get; set; } | ||||
|     public string MID { get; set; } | ||||
|     // | ||||
|     public string Date { get; set; } | ||||
|     public string Employee { get; set; } | ||||
|     public string Lot { get; set; } | ||||
|     public string PSN { get; set; } | ||||
|     public string Reactor { get; set; } | ||||
|     public string Recipe { get; set; } | ||||
|     [JsonPropertyName("Date")] public string Date { get; set; } | ||||
|     [JsonPropertyName("Operator")] public string Employee { get; set; } | ||||
|     [JsonPropertyName("Lot")] public string Lot { get; set; } | ||||
|     [JsonPropertyName("PSN")] public string PSN { get; set; } | ||||
|     [JsonPropertyName("Reactor")] public string Reactor { get; set; } | ||||
|     [JsonPropertyName("RecipeName")] public string Recipe { get; set; } | ||||
|     // | ||||
|     public string AutoOptimizeGain { get; set; } | ||||
|     public string AutoProbeHeightSet { get; set; } | ||||
|     public string Avg { get; set; } | ||||
|     public string DataReject { get; set; } | ||||
|     public string DLRatio { get; set; } | ||||
|     public string Merit { get; set; } | ||||
|     public string Pt { get; set; } | ||||
|     public string R { get; set; } | ||||
|     public string ResistivitySpec { get; set; } | ||||
|     public string Rs { get; set; } | ||||
|     public string SemiRadial { get; set; } | ||||
|     public string StdDev { get; set; } | ||||
|     public string T { get; set; } | ||||
|     public string Temp { get; set; } | ||||
|     [JsonPropertyName("AutoOptimizeGain")] public string AutoOptimizeGain { get; set; } | ||||
|     [JsonPropertyName("AutoProbeHeightSet")] public string AutoProbeHeightSet { get; set; } | ||||
|     [JsonPropertyName("Avg")] public string Avg { get; set; } | ||||
|     [JsonPropertyName("DataRejectSigma")] public string DataReject { get; set; } | ||||
|     [JsonPropertyName("DLRatio")] public string DLRatio { get; set; } | ||||
|     [JsonPropertyName("MeritGOF")] public string Merit { get; set; } | ||||
|     [JsonPropertyName("InferredPoint")] public string Pt { get; set; } | ||||
|     [JsonPropertyName("R")] public string R { get; set; } | ||||
|     [JsonPropertyName("ResistivitySpec")] public string ResistivitySpec { get; set; } | ||||
|     [JsonPropertyName("Rs")] public string Rs { get; set; } | ||||
|     [JsonPropertyName("SemiRadial")] public string SemiRadial { get; set; } | ||||
|     [JsonPropertyName("StandardDeviationPercentage")] public string StdDev { get; set; } | ||||
|     [JsonPropertyName("Th")] public string T { get; set; } | ||||
|     [JsonPropertyName("Temp")] public string Temp { get; set; } | ||||
|     // | ||||
|     public string Engineer { get; set; } | ||||
|     public string EquipId { get; set; } | ||||
|     public string FileName { get; set; } | ||||
|     [JsonPropertyName("Engineer")] public string Engineer { get; set; } | ||||
|     [JsonPropertyName("Equipment")] public string EquipId { get; set; } | ||||
|     [JsonPropertyName("TheFileName")] public string FileName { get; set; } | ||||
|     public string HeaderUniqueId { get; set; } | ||||
|     public string Id { get; set; } | ||||
|     public string Layer { get; set; } | ||||
|     public string RDS { get; set; } | ||||
|     public string Run { get; set; } | ||||
|     [JsonPropertyName("Layer")] public string Layer { get; set; } | ||||
|     [JsonPropertyName("RDS")] public string RDS { get; set; } | ||||
|     [JsonPropertyName("Title")] public string Run { get; set; } | ||||
|     public string UniqueId { get; set; } | ||||
|     public string Zone { get; set; } | ||||
|     [JsonPropertyName("Zone")] public string Zone { get; set; } | ||||
|     // | ||||
|     public string SheetRhoVariation { get; set; } | ||||
|     [JsonPropertyName("SheetRhoVariation")] public string SheetRhoVariation { get; set; } | ||||
|  | ||||
|     string IDescription.GetEventDescription() => "File Has been read and parsed"; | ||||
|  | ||||
| @ -314,4 +315,16 @@ public class Description : IDescription, Shared.Properties.IDescription | ||||
|  | ||||
|     internal static string GetDateFormat() => "MM/dd/yyyy hh:mm:ss tt"; | ||||
|  | ||||
| } | ||||
|  | ||||
| [JsonSourceGenerationOptions(WriteIndented = true, NumberHandling = JsonNumberHandling.AllowReadingFromString | JsonNumberHandling.WriteAsString)] | ||||
| [JsonSerializable(typeof(Description))] | ||||
| internal partial class DescriptionSourceGenerationContext : JsonSerializerContext | ||||
| { | ||||
| } | ||||
|  | ||||
| [JsonSourceGenerationOptions(WriteIndented = true, NumberHandling = JsonNumberHandling.AllowReadingFromString | JsonNumberHandling.WriteAsString)] | ||||
| [JsonSerializable(typeof(Description[]))] | ||||
| internal partial class DescriptionArraySourceGenerationContext : JsonSerializerContext | ||||
| { | ||||
| } | ||||
| @ -1,16 +1,30 @@ | ||||
| namespace Adaptation.FileHandlers.RsM; | ||||
| using System.Text.Json.Serialization; | ||||
|  | ||||
| namespace Adaptation.FileHandlers.RsM; | ||||
|  | ||||
| public class Detail | ||||
| { | ||||
|  | ||||
|     public string HeaderUniqueId { get; set; } | ||||
|     public string Merit { get; set; } | ||||
|     public string Pt { get; set; } | ||||
|     public string R { get; set; } | ||||
|     public string Rs { get; set; } | ||||
|     public string T { get; set; } | ||||
|     [JsonPropertyName("MeritGOF")] public string Merit { get; set; } | ||||
|     [JsonPropertyName("InferredPoint")] public string Pt { get; set; } | ||||
|     [JsonPropertyName("R")] public string R { get; set; } | ||||
|     [JsonPropertyName("Rs")] public string Rs { get; set; } | ||||
|     [JsonPropertyName("Th")] public string T { get; set; } | ||||
|     public string UniqueId { get; set; } | ||||
|  | ||||
|     public override string ToString() => string.Concat(Merit, ";", Pt, ";", R, ";", Rs, ";", T); | ||||
|  | ||||
| } | ||||
|  | ||||
| [JsonSourceGenerationOptions(WriteIndented = true, NumberHandling = JsonNumberHandling.AllowReadingFromString | JsonNumberHandling.WriteAsString)] | ||||
| [JsonSerializable(typeof(Detail))] | ||||
| internal partial class DetailSourceGenerationContext : JsonSerializerContext | ||||
| { | ||||
| } | ||||
|  | ||||
| [JsonSourceGenerationOptions(WriteIndented = true, NumberHandling = JsonNumberHandling.AllowReadingFromString | JsonNumberHandling.WriteAsString)] | ||||
| [JsonSerializable(typeof(Detail[]))] | ||||
| internal partial class DetailArraySourceGenerationContext : JsonSerializerContext | ||||
| { | ||||
| } | ||||
| @ -15,7 +15,7 @@ public class FileRead : Shared.FileRead, IFileRead | ||||
|  | ||||
|     private long? _TickOffset; | ||||
|  | ||||
|     public FileRead(ISMTP smtp, Dictionary<string, string> fileParameter, string cellInstanceName, int? connectionCount, string cellInstanceConnectionName, FileConnectorConfiguration fileConnectorConfiguration, string equipmentTypeName, string parameterizedModelObjectDefinitionType, IList<ModelObjectParameterDefinition> modelObjectParameters, string equipmentDictionaryName, Dictionary<string, List<long>> dummyRuns, Dictionary<long, List<string>> staticRuns, bool useCyclicalForDescription, bool isEAFHosted) : | ||||
|     public FileRead(ISMTP smtp, Dictionary<string, string> fileParameter, string cellInstanceName, int? connectionCount, string cellInstanceConnectionName, FileConnectorConfiguration fileConnectorConfiguration, string equipmentTypeName, string parameterizedModelObjectDefinitionType, IList<ModelObjectParameterDefinition> modelObjectParameters, string equipmentDictionaryName, Dictionary<string, List<long>> dummyRuns, Dictionary<long, List<Shared.Metrology.WS.Results>> staticRuns, bool useCyclicalForDescription, bool isEAFHosted) : | ||||
|         base(new Description(), true, smtp, fileParameter, cellInstanceName, connectionCount, cellInstanceConnectionName, fileConnectorConfiguration, equipmentTypeName, parameterizedModelObjectDefinitionType, modelObjectParameters, equipmentDictionaryName, dummyRuns, staticRuns, useCyclicalForDescription, isEAFHosted: connectionCount is null) | ||||
|     { | ||||
|         _MinFileLength = 10; | ||||
| @ -108,30 +108,34 @@ public class FileRead : Shared.FileRead, IFileRead | ||||
|             results.Item4.Add(_Logistics.FileInfo); | ||||
|         else | ||||
|         { | ||||
|             Complete? complete = Complete.Get(_Logistics, results.Item4); | ||||
|             if (complete is null) | ||||
|             Run? run = Run.Get(_Logistics, results.Item4); | ||||
|             if (run is null) | ||||
|                 throw new Exception(string.Concat("A) No Data - ", dateTime.Ticks)); | ||||
|             IProcessData iProcessData = new ProcessData(this, _Logistics, results.Item4, complete); | ||||
|             IProcessData iProcessData = new ProcessData(this, _Logistics, results.Item4, run); | ||||
|             if (iProcessData is not ProcessData processData) | ||||
|                 throw new Exception(string.Concat("B) No Data - ", dateTime.Ticks)); | ||||
|             string mid; | ||||
|             if (!string.IsNullOrEmpty(processData.Run) && string.IsNullOrEmpty(processData.Reactor) && string.IsNullOrEmpty(processData.RDS) && string.IsNullOrEmpty(processData.PSN)) | ||||
|                 mid = processData.Run; | ||||
|             else if (!string.IsNullOrEmpty(processData.Employee) && string.IsNullOrEmpty(processData.Reactor) && string.IsNullOrEmpty(processData.RDS) && string.IsNullOrEmpty(processData.PSN)) | ||||
|                 mid = processData.Employee; | ||||
|                 results = new(string.Concat("B) No Data - ", dateTime.Ticks), Array.Empty<Test>(), Array.Empty<JsonElement>(), results.Item4); | ||||
|             else | ||||
|             { | ||||
|                 mid = string.Concat(processData.Reactor, "-", processData.RDS, "-", processData.PSN); | ||||
|                 mid = Regex.Replace(mid, @"[\\,\/,\:,\*,\?,\"",\<,\>,\|]", "_").Split('\r')[0].Split('\n')[0]; | ||||
|                 string mid; | ||||
|                 if (!string.IsNullOrEmpty(processData.Run) && string.IsNullOrEmpty(processData.Reactor) && string.IsNullOrEmpty(processData.RDS) && string.IsNullOrEmpty(processData.PSN)) | ||||
|                     mid = processData.Run; | ||||
|                 else if (!string.IsNullOrEmpty(processData.Employee) && string.IsNullOrEmpty(processData.Reactor) && string.IsNullOrEmpty(processData.RDS) && string.IsNullOrEmpty(processData.PSN)) | ||||
|                     mid = processData.Employee; | ||||
|                 else | ||||
|                 { | ||||
|                     mid = string.Concat(processData.Reactor, "-", processData.RDS, "-", processData.PSN); | ||||
|                     mid = Regex.Replace(mid, @"[\\,\/,\:,\*,\?,\"",\<,\>,\|]", "_").Split('\r')[0].Split('\n')[0]; | ||||
|                 } | ||||
|                 SetFileParameterLotID(mid); | ||||
|                 _Logistics.Update(mid, processData.Reactor); | ||||
|                 string logBody = processData.LogBody; | ||||
|                 if (iProcessData.Details.Count > 0) | ||||
|                     results = iProcessData.GetResults(this, _Logistics, results.Item4); | ||||
|                 else | ||||
|                     results = new(string.Concat("C) No Data - ", dateTime.Ticks), Array.Empty<Test>(), Array.Empty<JsonElement>(), results.Item4); | ||||
|                 if (!_IsEAFHosted) | ||||
|                     results = new(logBody, results.Item2, results.Item3, results.Item4); | ||||
|             } | ||||
|             SetFileParameterLotID(mid); | ||||
|             _Logistics.Update(mid, processData.Reactor); | ||||
|             string logBody = processData.LogBody; | ||||
|             if (iProcessData.Details.Count == 0) | ||||
|                 throw new Exception(string.Concat("C) No Data - ", dateTime.Ticks)); | ||||
|             results = iProcessData.GetResults(this, _Logistics, results.Item4); | ||||
|             if (!_IsEAFHosted) | ||||
|                 results = new(logBody, results.Item2, results.Item3, results.Item4); | ||||
|         } | ||||
|         return results; | ||||
|     } | ||||
|  | ||||
| @ -15,7 +15,7 @@ internal record Line1 | ||||
|     internal static Line1 Get(string[] segments) | ||||
|     { | ||||
|         Line1 result; | ||||
|         ReadOnlyCollection<string> collection = Complete.GetCollection(segments); | ||||
|         ReadOnlyCollection<string> collection = Run.GetCollection(segments); | ||||
|         result = new(collection.Count < 1 ? string.Empty : collection[0]); | ||||
|         return result; | ||||
|     } | ||||
|  | ||||
| @ -23,7 +23,7 @@ internal record Line10 | ||||
|     internal static Line10 Get(string[] segments) | ||||
|     { | ||||
|         Line10 result; | ||||
|         ReadOnlyCollection<string> collection = Complete.GetCollection(segments); | ||||
|         ReadOnlyCollection<string> collection = Run.GetCollection(segments); | ||||
|         result = new(collection.Count < 1 ? string.Empty : collection[0], | ||||
|                      collection.Count < 2 ? string.Empty : collection[1], | ||||
|                      collection.Count < 3 ? string.Empty : collection[2], | ||||
|  | ||||
| @ -33,7 +33,7 @@ internal record Line11 | ||||
|     internal static Line11 Get(string[] segments) | ||||
|     { | ||||
|         Line11 result; | ||||
|         ReadOnlyCollection<string> collection = Complete.GetCollection(segments); | ||||
|         ReadOnlyCollection<string> collection = Run.GetCollection(segments); | ||||
|         result = new(collection.Count < 1 ? string.Empty : collection[0], | ||||
|                      collection.Count < 2 ? string.Empty : collection[1], | ||||
|                      collection.Count < 3 ? string.Empty : collection[2], | ||||
|  | ||||
| @ -19,7 +19,7 @@ internal record Line12 | ||||
|     internal static Line12 Get(string[] segments) | ||||
|     { | ||||
|         Line12 result; | ||||
|         ReadOnlyCollection<string> collection = Complete.GetCollection(segments); | ||||
|         ReadOnlyCollection<string> collection = Run.GetCollection(segments); | ||||
|         result = new(collection.Count < 1 ? string.Empty : collection[0], | ||||
|                      collection.Count < 2 ? string.Empty : collection[1]); | ||||
|         return result; | ||||
|  | ||||
| @ -15,7 +15,7 @@ internal record Line13 | ||||
|     internal static Line13 Get(string[] segments) | ||||
|     { | ||||
|         Line13 result; | ||||
|         ReadOnlyCollection<string> collection = Complete.GetCollection(segments); | ||||
|         ReadOnlyCollection<string> collection = Run.GetCollection(segments); | ||||
|         result = new(collection.Count < 1 ? string.Empty : collection[0]); | ||||
|         return result; | ||||
|     } | ||||
|  | ||||
| @ -27,7 +27,7 @@ internal record Line2 | ||||
|     internal static Line2 Get(string[] segments) | ||||
|     { | ||||
|         Line2 result; | ||||
|         ReadOnlyCollection<string> collection = Complete.GetCollection(segments); | ||||
|         ReadOnlyCollection<string> collection = Run.GetCollection(segments); | ||||
|         result = new(collection.Count < 1 ? string.Empty : collection[0], | ||||
|                      collection.Count < 2 ? string.Empty : collection[1], | ||||
|                      collection.Count < 3 ? string.Empty : collection[2], | ||||
|  | ||||
| @ -15,7 +15,7 @@ internal record Line3 | ||||
|     internal static Line3 Get(string[] segments) | ||||
|     { | ||||
|         Line3 result; | ||||
|         ReadOnlyCollection<string> collection = Complete.GetCollection(segments); | ||||
|         ReadOnlyCollection<string> collection = Run.GetCollection(segments); | ||||
|         result = new(collection.Count < 1 ? string.Empty : collection[0]); | ||||
|         return result; | ||||
|     } | ||||
|  | ||||
| @ -25,7 +25,7 @@ internal record Line4 | ||||
|     internal static Line4 Get(string[] segments) | ||||
|     { | ||||
|         Line4 result; | ||||
|         ReadOnlyCollection<string> collection = Complete.GetCollection(segments); | ||||
|         ReadOnlyCollection<string> collection = Run.GetCollection(segments); | ||||
|         result = new(collection.Count < 1 ? string.Empty : collection[0], | ||||
|                      collection.Count < 2 ? string.Empty : collection[1], | ||||
|                      collection.Count < 3 ? string.Empty : collection[2], | ||||
|  | ||||
| @ -19,7 +19,7 @@ internal record Line5 | ||||
|     internal static Line5 Get(string[] segments) | ||||
|     { | ||||
|         Line5 result; | ||||
|         ReadOnlyCollection<string> collection = Complete.GetCollection(segments); | ||||
|         ReadOnlyCollection<string> collection = Run.GetCollection(segments); | ||||
|         result = new(collection.Count < 1 ? string.Empty : collection[0], | ||||
|                      collection.Count < 2 ? string.Empty : collection[1]); | ||||
|         return result; | ||||
|  | ||||
| @ -15,7 +15,7 @@ internal record Line6 | ||||
|     internal static Line6 Get(string[] segments) | ||||
|     { | ||||
|         Line6 result; | ||||
|         ReadOnlyCollection<string> collection = Complete.GetCollection(segments); | ||||
|         ReadOnlyCollection<string> collection = Run.GetCollection(segments); | ||||
|         result = new(collection.Count < 1 ? string.Empty : collection[0]); | ||||
|         return result; | ||||
|     } | ||||
|  | ||||
| @ -35,7 +35,7 @@ internal record Line7 | ||||
|     internal static Line7 Get(string[] segments) | ||||
|     { | ||||
|         Line7 result; | ||||
|         ReadOnlyCollection<string> collection = Complete.GetCollection(segments); | ||||
|         ReadOnlyCollection<string> collection = Run.GetCollection(segments); | ||||
|         result = new(collection.Count < 1 ? string.Empty : collection[0], | ||||
|                      collection.Count < 2 ? string.Empty : collection[1], | ||||
|                      collection.Count < 3 ? string.Empty : collection[2], | ||||
|  | ||||
| @ -35,7 +35,7 @@ internal record Line8 | ||||
|     internal static Line8 Get(string[] segments) | ||||
|     { | ||||
|         Line8 result; | ||||
|         ReadOnlyCollection<string> collection = Complete.GetCollection(segments); | ||||
|         ReadOnlyCollection<string> collection = Run.GetCollection(segments); | ||||
|         result = new(collection.Count < 1 ? string.Empty : collection[0], | ||||
|                      collection.Count < 2 ? string.Empty : collection[1], | ||||
|                      collection.Count < 3 ? string.Empty : collection[2], | ||||
|  | ||||
| @ -33,7 +33,7 @@ internal class Line9 | ||||
|     internal static Line9 Get(string[] segments) | ||||
|     { | ||||
|         Line9 result; | ||||
|         ReadOnlyCollection<string> collection = Complete.GetCollection(segments); | ||||
|         ReadOnlyCollection<string> collection = Run.GetCollection(segments); | ||||
|         result = new(collection.Count < 1 ? string.Empty : collection[0], | ||||
|                      collection.Count < 2 ? string.Empty : collection[1], | ||||
|                      collection.Count < 3 ? string.Empty : collection[2], | ||||
|  | ||||
| @ -53,7 +53,7 @@ internal record Point | ||||
|             if (string.IsNullOrEmpty(lines[i])) | ||||
|                 break; | ||||
|             segments = lines[i].Split(separator, StringSplitOptions.RemoveEmptyEntries); | ||||
|             collection = Complete.GetCollection(segments); | ||||
|             collection = Run.GetCollection(segments); | ||||
|             point = new(collection.Count < 1 ? string.Empty : collection[0], | ||||
|                         collection.Count < 2 ? string.Empty : collection[1], | ||||
|                         collection.Count < 3 ? string.Empty : collection[2], | ||||
|  | ||||
| @ -53,13 +53,13 @@ public class ProcessData : IProcessData | ||||
|     private readonly ILog _Log; | ||||
|     List<object> Shared.Properties.IProcessData.Details => _Details; | ||||
|  | ||||
|     internal ProcessData(IFileRead fileRead, Logistics logistics, List<FileInfo> fileInfoCollection, Complete complete) | ||||
|     internal ProcessData(IFileRead fileRead, Logistics logistics, List<FileInfo> fileInfoCollection, Run run) | ||||
|     { | ||||
|         JobID = logistics.JobID; | ||||
|         _Details = new List<object>(); | ||||
|         MesEntity = logistics.MesEntity; | ||||
|         _Log = LogManager.GetLogger(typeof(ProcessData)); | ||||
|         Parse(fileRead, logistics, fileInfoCollection, complete); | ||||
|         Parse(fileRead, logistics, fileInfoCollection, run); | ||||
|     } | ||||
|  | ||||
|     string IProcessData.GetCurrentReactor(IFileRead fileRead, Logistics logistics, Dictionary<string, string> reactors) => throw new Exception(string.Concat("See ", nameof(Parse))); | ||||
| @ -80,9 +80,13 @@ public class ProcessData : IProcessData | ||||
|             if (description.Test != (int)tests[i]) | ||||
|                 throw new Exception(); | ||||
|         } | ||||
|         FileInfo fileInfo = new($"{logistics.ReportFullPath}.descriptions.json"); | ||||
|         List<Description> fileReadDescriptions = (from l in descriptions select (Description)l).ToList(); | ||||
|         string json = JsonSerializer.Serialize(fileReadDescriptions, fileReadDescriptions.GetType()); | ||||
|         JsonElement[] jsonElements = JsonSerializer.Deserialize<JsonElement[]>(json); | ||||
|         File.WriteAllText(fileInfo.FullName, json); | ||||
|         File.SetLastWriteTime(fileInfo.FullName, logistics.DateTimeFromSequence); | ||||
|         fileInfoCollection.Add(fileInfo); | ||||
|         JsonElement[] jsonElements = JsonSerializer.Deserialize<JsonElement[]>(json) ?? throw new Exception(); | ||||
|         results = new Tuple<string, Test[], JsonElement[], List<FileInfo>>(logistics.Logistics1[0], tests.ToArray(), jsonElements, fileInfoCollection); | ||||
|         return results; | ||||
|     } | ||||
| @ -215,10 +219,10 @@ public class ProcessData : IProcessData | ||||
|         return result; | ||||
|     } | ||||
|  | ||||
|     private void SetTitleData(Logistics logistics, Complete complete) | ||||
|     private void SetTitleData(Logistics logistics, Run run) | ||||
|     { | ||||
|         string timeFormat = "yyyyMMddHHmmss"; | ||||
|         Descriptor descriptor = GetDescriptor(complete.Line1.Title); | ||||
|         Descriptor descriptor = GetDescriptor(run.Line1.Title); | ||||
|         PSN = descriptor.PSN; | ||||
|         RDS = descriptor.RDS; | ||||
|         Run = descriptor.Run; | ||||
| @ -321,7 +325,7 @@ public class ProcessData : IProcessData | ||||
|  | ||||
| #nullable enable | ||||
|  | ||||
|     private void Parse(IFileRead fileRead, Logistics logistics, List<FileInfo> fileInfoCollection, Complete complete) | ||||
|     private void Parse(IFileRead fileRead, Logistics logistics, List<FileInfo> fileInfoCollection, Run run) | ||||
|     { | ||||
|         if (fileRead is null) | ||||
|             throw new ArgumentNullException(nameof(fileRead)); | ||||
| @ -334,7 +338,7 @@ public class ProcessData : IProcessData | ||||
|         { | ||||
|             segments = lines[i].Split(separator, StringSplitOptions.RemoveEmptyEntries); | ||||
|             if (lines[i].Contains("<Title>") && segments.Length > 0) | ||||
|                 SetTitleData(logistics, complete); | ||||
|                 SetTitleData(logistics, run); | ||||
|             else if (lines[i].Contains("<FileName, Proj,Rcpe, LotID,WfrID")) | ||||
|                 SetFileNameData(segments); | ||||
|             else if (lines[i].Contains("<DateTime,Temp,TCR%,N|P>")) | ||||
| @ -391,12 +395,11 @@ public class ProcessData : IProcessData | ||||
|     { | ||||
|         List<Description> results = new(); | ||||
|         Description? description; | ||||
|         JsonSerializerOptions jsonSerializerOptions = new() { NumberHandling = JsonNumberHandling.AllowReadingFromString | JsonNumberHandling.WriteAsString }; | ||||
|         foreach (JsonElement jsonElement in jsonElements) | ||||
|         { | ||||
|             if (jsonElement.ValueKind != JsonValueKind.Object) | ||||
|                 throw new Exception(); | ||||
|             description = JsonSerializer.Deserialize<Description>(jsonElement.ToString(), jsonSerializerOptions); | ||||
|             description = JsonSerializer.Deserialize(jsonElement.ToString(), DescriptionSourceGenerationContext.Default.Description); | ||||
|             if (description is null) | ||||
|                 continue; | ||||
|             results.Add(description); | ||||
|  | ||||
							
								
								
									
										211
									
								
								Adaptation/FileHandlers/RsM/Row.cs
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										211
									
								
								Adaptation/FileHandlers/RsM/Row.cs
									
									
									
									
									
										Normal file
									
								
							| @ -0,0 +1,211 @@ | ||||
| using System.Text.Json.Serialization; | ||||
|  | ||||
| namespace Adaptation.FileHandlers.RsM; | ||||
|  | ||||
| #nullable enable | ||||
|  | ||||
| internal class Row | ||||
| { | ||||
|  | ||||
|     public Row(Run run, int i) | ||||
|     { | ||||
|         Index = i; | ||||
|         // | ||||
|         Title = run.Line1.Title; | ||||
|         // | ||||
|         FileName = run.Line2.FileName; | ||||
|         Project = run.Line2.Project; | ||||
|         RecipeName = run.Line2.RecipeName; | ||||
|         LotID = run.Line2.LotID; | ||||
|         WfrID = run.Line2.WfrID; | ||||
|         Is_TF_DataFile = run.Line2.Is_TF_DataFile; | ||||
|         // | ||||
|         Directory = run.Line3.Directory; | ||||
|         // | ||||
|         Time = run.Line4.Time; | ||||
|         Date = run.Line4.Date; | ||||
|         Temp = run.Line4.Temp; | ||||
|         TCRPercent = run.Line4.TCRPercent; | ||||
|         NOrP = run.Line4.NOrP; | ||||
|         // | ||||
|         Avg = run.Line4B.Avg; | ||||
|         Dev = run.Line4B.Dev; | ||||
|         Min = run.Line4B.Min; | ||||
|         Max = run.Line4B.Max; | ||||
|         // | ||||
|         Operator = run.Line5.Operator; | ||||
|         Equipment = run.Line5.Equipment; | ||||
|         // | ||||
|         Engineer = run.Line6.Engineer; | ||||
|         // | ||||
|         AreaOrDiamScan = run.Line7.AreaOrDiamScan; | ||||
|         WaferShape = run.Line7.WaferShape; | ||||
|         BNBand = run.Line7.BNBand; | ||||
|         TemplateFile = run.Line7.TemplateFile; | ||||
|         XSize = run.Line7.XSize; | ||||
|         YSize = run.Line7.YSize; | ||||
|         CalibrationFactor = run.Line7.CalibrationFactor; | ||||
|         MsmtMode = run.Line7.MsmtMode; | ||||
|         DataType = run.Line7.DataType; | ||||
|         DataUnit = run.Line7.DataUnit; | ||||
|         // | ||||
|         NumProbePoints = run.Line8.NumProbePoints; | ||||
|         SingleOrDualProbeConfig = run.Line8.SingleOrDualProbeConfig; | ||||
|         NumberActPrbPts = run.Line8.NumberActPrbPts; | ||||
|         Rsens = run.Line8.Rsens; | ||||
|         IdrvMx = run.Line8.IdrvMx; | ||||
|         VinGain = run.Line8.VinGain; | ||||
|         DataRejectSigma = run.Line8.DataRejectSigma; | ||||
|         MeritThreshold = run.Line8.MeritThreshold; | ||||
|         PrbChgNumber = run.Line8.PrbChgNumber; | ||||
|         PrbName = run.Line8.PrbName; | ||||
|         // | ||||
|         WaferSize = run.Line9.WaferSize; | ||||
|         EdgeEx = run.Line9.EdgeEx; | ||||
|         Xll = run.Line9.Xll; | ||||
|         Yll = run.Line9.Yll; | ||||
|         Xur = run.Line9.Xur; | ||||
|         Yur = run.Line9.Yur; | ||||
|         X = run.Line9.X; | ||||
|         Y = run.Line9.Y; | ||||
|         CutCorners = run.Line9.CutCorners; | ||||
|         // | ||||
|         DiamThScan = run.Line10.DiamThScan; | ||||
|         DiamStart = run.Line10.DiamStart; | ||||
|         DiamEnd = run.Line10.DiamEnd; | ||||
|         DiamStep = run.Line10.DiamStep; | ||||
|         // | ||||
|         FlatOrNotch = run.Line11.FlatOrNotch; | ||||
|         FollowMajorFlat = run.Line11.FollowMajorFlat; | ||||
|         AutoOrManualLoad = run.Line11.AutoOrManualLoad; | ||||
|         RangeOrIndividual = run.Line11.RangeOrIndividual; | ||||
|         PauseAfterEveryRun = run.Line11.PauseAfterEveryRun; | ||||
|         AutoPrint = run.Line11.AutoPrint; | ||||
|         Plot = run.Line11.Plot; | ||||
|         BulkSampleThk = run.Line11.BulkSampleThk; | ||||
|         Unit = run.Line11.Unit; | ||||
|         // | ||||
|         RangeFrom = run.Line12.RangeFrom; | ||||
|         RangeTo = run.Line12.RangeTo; | ||||
|         // | ||||
|         CassetteSlotSelected = run.Line13.CassetteSlotSelected; | ||||
|         // | ||||
|         R = run.Points[i].R; | ||||
|         Th = run.Points[i].Th; | ||||
|         Data = run.Points[i].Data; | ||||
|         Rs = run.Points[i].Rs; | ||||
|         RsA = run.Points[i].RsA; | ||||
|         RsB = run.Points[i].RsB; | ||||
|         NumberSample = run.Points[i].NumberSample; | ||||
|         PointX = run.Points[i].X; | ||||
|         PointY = run.Points[i].Y; | ||||
|         Irng = run.Points[i].Irng; | ||||
|         Vrng = run.Points[i].Vrng; | ||||
|         ChiSq = run.Points[i].ChiSq; | ||||
|         MeritGOF = run.Points[i].MeritGOF; | ||||
|         DataIntegrity = run.Points[i].DataIntegrity; | ||||
|     } | ||||
|  | ||||
|     public int Index { get; } | ||||
|     // | ||||
|     public string Title { get; } | ||||
|     // | ||||
|     public string FileName { get; } | ||||
|     public string Project { get; } | ||||
|     public string RecipeName { get; } | ||||
|     public string LotID { get; } | ||||
|     public string WfrID { get; } | ||||
|     public string Is_TF_DataFile { get; } | ||||
|     // | ||||
|     public string Directory { get; } | ||||
|     // | ||||
|     public string Time { get; } | ||||
|     public string Date { get; } | ||||
|     public string Temp { get; } | ||||
|     public string TCRPercent { get; } | ||||
|     public string NOrP { get; } | ||||
|     // | ||||
|     public string Avg { get; } | ||||
|     public string Dev { get; } | ||||
|     public string Min { get; } | ||||
|     public string Max { get; } | ||||
|     // | ||||
|     public string Operator { get; } | ||||
|     public string Equipment { get; } | ||||
|     // | ||||
|     public string Engineer { get; } | ||||
|     // | ||||
|     public string AreaOrDiamScan { get; } | ||||
|     public string WaferShape { get; } | ||||
|     public string BNBand { get; } | ||||
|     public string TemplateFile { get; } | ||||
|     public string XSize { get; } | ||||
|     public string YSize { get; } | ||||
|     public string CalibrationFactor { get; } | ||||
|     public string MsmtMode { get; } | ||||
|     public string DataType { get; } | ||||
|     public string DataUnit { get; } | ||||
|     // | ||||
|     public string NumProbePoints { get; } | ||||
|     public string SingleOrDualProbeConfig { get; } | ||||
|     public string NumberActPrbPts { get; } | ||||
|     public string Rsens { get; } | ||||
|     public string IdrvMx { get; } | ||||
|     public string VinGain { get; } | ||||
|     public string DataRejectSigma { get; } | ||||
|     public string MeritThreshold { get; } | ||||
|     public string PrbChgNumber { get; } | ||||
|     public string PrbName { get; } | ||||
|     // | ||||
|     public string WaferSize { get; } | ||||
|     public string EdgeEx { get; } | ||||
|     public string Xll { get; } | ||||
|     public string Yll { get; } | ||||
|     public string Xur { get; } | ||||
|     public string Yur { get; } | ||||
|     public string X { get; } | ||||
|     public string Y { get; } | ||||
|     public string CutCorners { get; } | ||||
|     // | ||||
|     public string DiamThScan { get; } | ||||
|     public string DiamStart { get; } | ||||
|     public string DiamEnd { get; } | ||||
|     public string DiamStep { get; } | ||||
|     // | ||||
|     public string FlatOrNotch { get; } | ||||
|     public string FollowMajorFlat { get; } | ||||
|     public string AutoOrManualLoad { get; } | ||||
|     public string RangeOrIndividual { get; } | ||||
|     public string PauseAfterEveryRun { get; } | ||||
|     public string AutoPrint { get; } | ||||
|     public string Plot { get; } | ||||
|     public string BulkSampleThk { get; } | ||||
|     public string Unit { get; } | ||||
|     // | ||||
|     public string RangeFrom { get; } | ||||
|     public string RangeTo { get; } | ||||
|     // | ||||
|     public string CassetteSlotSelected { get; } | ||||
|     // | ||||
|     public string R { get; } | ||||
|     public string Th { get; } | ||||
|     public string Data { get; } | ||||
|     public string Rs { get; } | ||||
|     public string RsA { get; } | ||||
|     public string RsB { get; } | ||||
|     public string NumberSample { get; } | ||||
|     public string PointX { get; } | ||||
|     public string PointY { get; } | ||||
|     public string Irng { get; } | ||||
|     public string Vrng { get; } | ||||
|     public string ChiSq { get; } | ||||
|     public string MeritGOF { get; } | ||||
|     public string DataIntegrity { get; } | ||||
|  | ||||
| } | ||||
|  | ||||
| [JsonSourceGenerationOptions(WriteIndented = true)] | ||||
| [JsonSerializable(typeof(Row))] | ||||
| internal partial class RowSourceGenerationContext : JsonSerializerContext | ||||
| { | ||||
| } | ||||
							
								
								
									
										192
									
								
								Adaptation/FileHandlers/RsM/Run.cs
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										192
									
								
								Adaptation/FileHandlers/RsM/Run.cs
									
									
									
									
									
										Normal file
									
								
							| @ -0,0 +1,192 @@ | ||||
| using Adaptation.Shared; | ||||
| using System; | ||||
| using System.Collections.Generic; | ||||
| using System.Collections.ObjectModel; | ||||
| using System.IO; | ||||
| using System.Text; | ||||
| using System.Text.Json; | ||||
| using System.Text.Json.Serialization; | ||||
|  | ||||
| namespace Adaptation.FileHandlers.RsM; | ||||
|  | ||||
| #nullable enable | ||||
|  | ||||
| internal class Run | ||||
| { | ||||
|     public Run(Line1 line1, Line2 line2, Line3 line3, Line4 line4, Line4B line4B, Line5 line5, Line6 line6, Line7 line7, Line8 line8, Line9 line9, Line10 line10, Line11 line11, Line12 line12, Line13 line13, ReadOnlyCollection<Point> points) | ||||
|     { | ||||
|         Line1 = line1; | ||||
|         Line2 = line2; | ||||
|         Line3 = line3; | ||||
|         Line4 = line4; | ||||
|         Line4B = line4B; | ||||
|         Line5 = line5; | ||||
|         Line6 = line6; | ||||
|         Line7 = line7; | ||||
|         Line8 = line8; | ||||
|         Line9 = line9; | ||||
|         Line10 = line10; | ||||
|         Line11 = line11; | ||||
|         Line12 = line12; | ||||
|         Line13 = line13; | ||||
|         Points = points; | ||||
|     } | ||||
|  | ||||
|     public Line1 Line1 { get; } | ||||
|     public Line2 Line2 { get; } | ||||
|     public Line3 Line3 { get; } | ||||
|     public Line4 Line4 { get; } | ||||
|     public Line4B Line4B { get; } | ||||
|     public Line5 Line5 { get; } | ||||
|     public Line6 Line6 { get; } | ||||
|     public Line7 Line7 { get; } | ||||
|     public Line8 Line8 { get; } | ||||
|     public Line9 Line9 { get; } | ||||
|     public Line10 Line10 { get; } | ||||
|     public Line11 Line11 { get; } | ||||
|     public Line12 Line12 { get; } | ||||
|     public Line13 Line13 { get; } | ||||
|     public ReadOnlyCollection<Point> Points { get; } | ||||
|  | ||||
|     internal static ReadOnlyCollection<string> GetCollection(string[] segments) | ||||
|     { | ||||
|         List<string> results = new(); | ||||
|         foreach (string segment in segments) | ||||
|         { | ||||
|             if (segment[0] == ',') | ||||
|                 break; | ||||
|             results.Add(segment); | ||||
|         } | ||||
|         return new(results); | ||||
|     } | ||||
|  | ||||
|     private static void WriteJson(Logistics logistics, List<FileInfo> fileInfoCollection, Run result) | ||||
|     { | ||||
|         FileInfo fileInfo = new($"{logistics.ReportFullPath}.run.json"); | ||||
|         string json = JsonSerializer.Serialize(result, RunSourceGenerationContext.Default.Run); | ||||
|         File.WriteAllText(fileInfo.FullName, json); | ||||
|         File.SetLastWriteTime(fileInfo.FullName, logistics.DateTimeFromSequence); | ||||
|         fileInfoCollection.Add(fileInfo); | ||||
|     } | ||||
|  | ||||
|     private static ReadOnlyCollection<string> GetLines(Logistics logistics, JsonElement[]? jsonElements) | ||||
|     { | ||||
|         List<string> results = new(); | ||||
|         int columns = 0; | ||||
|         StringBuilder stringBuilder = new(); | ||||
|         results.Add($"\"Count\",{jsonElements?.Length}"); | ||||
|         results.Add($"\"{nameof(logistics.Sequence)}\",\"{logistics.Sequence}\""); | ||||
|         results.Add($"\"{nameof(logistics.MesEntity)}\",\"{logistics.MesEntity}\""); | ||||
|         string dateTimeFromSequence = logistics.DateTimeFromSequence.ToString("MM/dd/yyyy hh:mm:ss tt"); | ||||
|         for (int i = 0; i < jsonElements?.Length;) | ||||
|         { | ||||
|             _ = stringBuilder.Append('"').Append(nameof(logistics.DateTimeFromSequence)).Append('"').Append(','); | ||||
|             foreach (JsonProperty jsonProperty in jsonElements[0].EnumerateObject()) | ||||
|             { | ||||
|                 columns += 1; | ||||
|                 _ = stringBuilder.Append('"').Append(jsonProperty.Name).Append('"').Append(','); | ||||
|             } | ||||
|             break; | ||||
|         } | ||||
|         if (jsonElements?.Length != 0) | ||||
|             _ = stringBuilder.Remove(stringBuilder.Length - 1, 1); | ||||
|         results.Add(stringBuilder.ToString()); | ||||
|         for (int i = 0; i < jsonElements?.Length; i++) | ||||
|         { | ||||
|             _ = stringBuilder.Clear(); | ||||
|             _ = stringBuilder.Append('"').Append(dateTimeFromSequence).Append('"').Append(','); | ||||
|             foreach (JsonProperty jsonProperty in jsonElements[i].EnumerateObject()) | ||||
|             { | ||||
|                 if (jsonProperty.Value.ValueKind == JsonValueKind.Object) | ||||
|                     _ = stringBuilder.Append(','); | ||||
|                 else if (jsonProperty.Value.ValueKind != JsonValueKind.String) | ||||
|                     _ = stringBuilder.Append(jsonProperty.Value).Append(','); | ||||
|                 else | ||||
|                     _ = stringBuilder.Append('"').Append(jsonProperty.Value).Append('"').Append(','); | ||||
|             } | ||||
|             _ = stringBuilder.Remove(stringBuilder.Length - 1, 1); | ||||
|             results.Add(stringBuilder.ToString()); | ||||
|         } | ||||
|         return results.AsReadOnly(); | ||||
|     } | ||||
|  | ||||
|     private static void WriteCommaSeparatedValues(Logistics logistics, Run run) | ||||
|     { | ||||
|         List<Row> results = new(); | ||||
|         Row row; | ||||
|         for (int i = 0; i < run.Points.Count; i++) | ||||
|         { | ||||
|             row = new(run, i); | ||||
|             results.Add(row); | ||||
|         } | ||||
|         string json = JsonSerializer.Serialize(results); | ||||
|         JsonElement[]? jsonElements = JsonSerializer.Deserialize<JsonElement[]>(json); | ||||
|         ReadOnlyCollection<string> lines = GetLines(logistics, jsonElements); | ||||
|         File.WriteAllText($"{logistics.ReportFullPath}.csv", string.Join(Environment.NewLine, lines)); | ||||
|     } | ||||
|  | ||||
|     internal static Run? Get(Logistics logistics, List<FileInfo> fileInfoCollection) | ||||
|     { | ||||
|         Run? result; | ||||
|         int take = 14; | ||||
|         string[] lines = File.ReadAllLines(logistics.ReportFullPath); | ||||
|         ReadOnlyCollection<string> collection = new(lines); | ||||
|         if (collection.Count < take) | ||||
|             result = null; | ||||
|         else | ||||
|         { | ||||
|             string[] separator = new string[] { " ", "\t" }; | ||||
|             // <Title> | ||||
|             Line1 line1 = Line1.Get(collection[0].Split(separator, StringSplitOptions.RemoveEmptyEntries)); | ||||
|             // <FileName, Proj,Rcpe, LotID,WfrID, Is_TF_DataFile> | ||||
|             Line2 line2 = Line2.Get(collection[1].Split(separator, StringSplitOptions.RemoveEmptyEntries)); | ||||
|             // <Directory> | ||||
|             Line3 line3 = Line3.Get(collection[2].Split(separator, StringSplitOptions.RemoveEmptyEntries)); | ||||
|             // <DateTime,Temp,TCR%,N|P> | ||||
|             Line4 line4 = Line4.Get(collection[3].Split(separator, StringSplitOptions.RemoveEmptyEntries)); | ||||
|             // <Avg,Dev,Min,Max> | ||||
|             Line4B? line4B = Line4B.Get(collection[3].Split(new string[] { ">" }, StringSplitOptions.RemoveEmptyEntries)); | ||||
|             if (line4B is null) | ||||
|                 result = null; | ||||
|             else | ||||
|             { | ||||
|                 // <Operator, Epuipment> | ||||
|                 Line5 line5 = Line5.Get(collection[4].Split(separator, StringSplitOptions.RemoveEmptyEntries)); | ||||
|                 // <Engineer> | ||||
|                 Line6 line6 = Line6.Get(collection[5].Split(separator, StringSplitOptions.RemoveEmptyEntries)); | ||||
|                 // <AreaOrDiamScan, WaferShape, dNBand,  TemplateFile,  xsize,ysize, CalibFactor, MsmtMode,  DataType,  DataUnit> | ||||
|                 Line7 line7 = Line7.Get(collection[6].Split(separator, StringSplitOptions.RemoveEmptyEntries)); | ||||
|                 // <NumProbePoints, SingleOrDualProbeConfig, #ActPrbPts,  Rsens,IdrvMx,VinGain, DataRejectSigma, MeritThreshold, PrbChg#, PrbName> | ||||
|                 Line8 line8 = Line8.Get(collection[7].Split(separator, StringSplitOptions.RemoveEmptyEntries)); | ||||
|                 // <WaferSize,EdgeEx, x,yll, x,yur, #x,y, CutCorners> | ||||
|                 Line9 line9 = Line9.Get(collection[8].Split(separator, StringSplitOptions.RemoveEmptyEntries)); | ||||
|                 // <Diam: ThScan Start End Step> | ||||
|                 Line10 line10 = Line10.Get(collection[9].Split(separator, StringSplitOptions.RemoveEmptyEntries)); | ||||
|                 // <FlatOrNotch FollowMajorFlat AutoOrManualLoad RangeOrIndvdual PauseAfterEveryRun, AutoPrint,Plot, BulkSmplThk & Unit> | ||||
|                 Line11 line11 = Line11.Get(collection[10].Split(separator, StringSplitOptions.RemoveEmptyEntries)); | ||||
|                 // <RangeFrom, RangeTo> | ||||
|                 Line12 line12 = Line12.Get(collection[11].Split(separator, StringSplitOptions.RemoveEmptyEntries)); | ||||
|                 // <CassSlotSelected> | ||||
|                 Line13 line13 = Line13.Get(collection[12].Split(separator, StringSplitOptions.RemoveEmptyEntries)); | ||||
|                 // <R,Th,Data, Rs,RsA,RsB, #Smpl, x,y, Irng,Vrng, ChiSq,merit/GOF, DataIntegrity> | ||||
|                 ReadOnlyCollection<Point> points = Point.Get(take, collection, separator); | ||||
|                 if (points.Count == 0) | ||||
|                     result = null; | ||||
|                 else | ||||
|                 { | ||||
|                     result = new(line1, line2, line3, line4, line4B, line5, line6, line7, line8, line9, line10, line11, line12, line13, points); | ||||
|                     WriteJson(logistics, fileInfoCollection, result); | ||||
|                     WriteCommaSeparatedValues(logistics, result); | ||||
|                 } | ||||
|             } | ||||
|         } | ||||
|         return result; | ||||
|     } | ||||
|  | ||||
| } | ||||
|  | ||||
| [JsonSourceGenerationOptions(WriteIndented = true)] | ||||
| [JsonSerializable(typeof(Run))] | ||||
| internal partial class RunSourceGenerationContext : JsonSerializerContext | ||||
| { | ||||
| } | ||||
| @ -14,7 +14,7 @@ namespace Adaptation.FileHandlers.SPaCe; | ||||
| public class FileRead : Shared.FileRead, IFileRead | ||||
| { | ||||
|  | ||||
|     public FileRead(ISMTP smtp, Dictionary<string, string> fileParameter, string cellInstanceName, int? connectionCount, string cellInstanceConnectionName, FileConnectorConfiguration fileConnectorConfiguration, string equipmentTypeName, string parameterizedModelObjectDefinitionType, IList<ModelObjectParameterDefinition> modelObjectParameters, string equipmentDictionaryName, Dictionary<string, List<long>> dummyRuns, Dictionary<long, List<string>> staticRuns, bool useCyclicalForDescription, bool isEAFHosted) : | ||||
|     public FileRead(ISMTP smtp, Dictionary<string, string> fileParameter, string cellInstanceName, int? connectionCount, string cellInstanceConnectionName, FileConnectorConfiguration fileConnectorConfiguration, string equipmentTypeName, string parameterizedModelObjectDefinitionType, IList<ModelObjectParameterDefinition> modelObjectParameters, string equipmentDictionaryName, Dictionary<string, List<long>> dummyRuns, Dictionary<long, List<Shared.Metrology.WS.Results>> staticRuns, bool useCyclicalForDescription, bool isEAFHosted) : | ||||
|         base(new Description(), false, smtp, fileParameter, cellInstanceName, connectionCount, cellInstanceConnectionName, fileConnectorConfiguration, equipmentTypeName, parameterizedModelObjectDefinitionType, modelObjectParameters, equipmentDictionaryName, dummyRuns, staticRuns, useCyclicalForDescription, isEAFHosted: connectionCount is null) | ||||
|     { | ||||
|         _MinFileLength = 10; | ||||
| @ -117,15 +117,15 @@ public class FileRead : Shared.FileRead, IFileRead | ||||
|     private Tuple<string, Test[], JsonElement[], List<FileInfo>> GetExtractResult(string reportFullPath, DateTime dateTime) | ||||
|     { | ||||
|         Tuple<string, Test[], JsonElement[], List<FileInfo>> results; | ||||
|         Tuple<string, string[], string[]> pdsf = ProcessDataStandardFormat.GetLogisticsColumnsAndBody(reportFullPath); | ||||
|         _Logistics = new Logistics(reportFullPath, pdsf.Item1); | ||||
|         ProcessDataStandardFormat processDataStandardFormat = ProcessDataStandardFormat.GetProcessDataStandardFormat(reportFullPath); | ||||
|         _Logistics = new Logistics(reportFullPath, processDataStandardFormat); | ||||
|         SetFileParameterLotIDToLogisticsMID(); | ||||
|         JsonElement[] jsonElements = ProcessDataStandardFormat.GetArray(pdsf); | ||||
|         JsonElement[] jsonElements = ProcessDataStandardFormat.GetArray(processDataStandardFormat); | ||||
|         List<Shared.Properties.IDescription> descriptions = GetDuplicatorDescriptions(jsonElements); | ||||
|         Test[] tests = (from l in descriptions select (Test)l.Test).ToArray(); | ||||
|         if (_IsEAFHosted && _FileConnectorConfiguration.FileScanningIntervalInSeconds > 0) | ||||
|             FileCopy(reportFullPath, dateTime, descriptions); | ||||
|         results = new Tuple<string, Test[], JsonElement[], List<FileInfo>>(pdsf.Item1, tests, jsonElements, new List<FileInfo>()); | ||||
|         results = new Tuple<string, Test[], JsonElement[], List<FileInfo>>(string.Join(Environment.NewLine, processDataStandardFormat.Logistics), tests, jsonElements, new List<FileInfo>()); | ||||
|         return results; | ||||
|     } | ||||
|  | ||||
|  | ||||
| @ -1,317 +0,0 @@ | ||||
| using Adaptation.Shared; | ||||
| using Adaptation.Shared.Methods; | ||||
| using System; | ||||
| using System.Collections.Generic; | ||||
| using System.Linq; | ||||
| using System.Text.Json; | ||||
|  | ||||
| namespace Adaptation.FileHandlers.txt; | ||||
|  | ||||
| public class Description : IDescription, Shared.Properties.IDescription | ||||
| { | ||||
|  | ||||
|     public int Test { get; set; } | ||||
|     public int Count { get; set; } | ||||
|     public int Index { get; set; } | ||||
|     // | ||||
|     public string EventName { get; set; } | ||||
|     public string NullData { get; set; } | ||||
|     public string JobID { get; set; } | ||||
|     public string Sequence { get; set; } | ||||
|     public string MesEntity { get; set; } | ||||
|     public string ReportFullPath { get; set; } | ||||
|     public string ProcessJobID { get; set; } | ||||
|     public string MID { get; set; } | ||||
|     // | ||||
|     public string Date { get; set; } | ||||
|     public string Employee { get; set; } | ||||
|     public string Lot { get; set; } | ||||
|     public string PSN { get; set; } | ||||
|     public string Reactor { get; set; } | ||||
|     public string Recipe { get; set; } | ||||
|     // | ||||
|     public string AutoOptimizeGain { get; set; } | ||||
|     public string AutoProbeHeightSet { get; set; } | ||||
|     public string Avg { get; set; } | ||||
|     public string DataReject { get; set; } | ||||
|     public string DLRatio { get; set; } | ||||
|     public string Merit { get; set; } | ||||
|     public string Pt { get; set; } | ||||
|     public string R { get; set; } | ||||
|     public string ResistivitySpec { get; set; } | ||||
|     public string Rs { get; set; } | ||||
|     public string SemiRadial { get; set; } | ||||
|     public string StdDev { get; set; } | ||||
|     public string T { get; set; } | ||||
|     public string Temp { get; set; } | ||||
|     // | ||||
|     public string Engineer { get; set; } | ||||
|     public string EquipId { get; set; } | ||||
|     public string FileName { get; set; } | ||||
|     public string HeaderUniqueId { get; set; } | ||||
|     public string Id { get; set; } | ||||
|     public string Layer { get; set; } | ||||
|     public string RDS { get; set; } | ||||
|     public string Run { get; set; } | ||||
|     public string UniqueId { get; set; } | ||||
|     public string Zone { get; set; } | ||||
|     // | ||||
|     public string SheetRhoVariation { get; set; } | ||||
|  | ||||
|     string IDescription.GetEventDescription() => "File Has been read and parsed"; | ||||
|  | ||||
|     List<string> IDescription.GetNames(IFileRead fileRead, Logistics logistics) | ||||
|     { | ||||
|         List<string> results = new(); | ||||
|         IDescription description = GetDefault(fileRead, logistics); | ||||
|         string json = JsonSerializer.Serialize(description, description.GetType()); | ||||
|         object @object = JsonSerializer.Deserialize<object>(json); | ||||
|         if (@object is not JsonElement jsonElement) | ||||
|             throw new Exception(); | ||||
|         foreach (JsonProperty jsonProperty in jsonElement.EnumerateObject()) | ||||
|             results.Add(jsonProperty.Name); | ||||
|         return results; | ||||
|     } | ||||
|  | ||||
|     List<string> IDescription.GetDetailNames() | ||||
|     { | ||||
|         List<string> results = new() | ||||
|         { | ||||
|             nameof(AutoOptimizeGain), | ||||
|             nameof(AutoProbeHeightSet), | ||||
|             nameof(Avg), | ||||
|             nameof(DataReject), | ||||
|             nameof(DLRatio), | ||||
|             nameof(Merit), | ||||
|             nameof(Pt), | ||||
|             nameof(R), | ||||
|             nameof(ResistivitySpec), | ||||
|             nameof(Rs), | ||||
|             nameof(SemiRadial), | ||||
|             nameof(StdDev), | ||||
|             nameof(T), | ||||
|             nameof(Temp) | ||||
|         }; | ||||
|         return results; | ||||
|     } | ||||
|  | ||||
|     List<string> IDescription.GetHeaderNames() | ||||
|     { | ||||
|         List<string> results = new() | ||||
|         { | ||||
|             nameof(Date), | ||||
|             nameof(Employee), | ||||
|             nameof(Lot), | ||||
|             nameof(PSN), | ||||
|             nameof(Reactor), | ||||
|             nameof(Recipe) | ||||
|         }; | ||||
|         return results; | ||||
|     } | ||||
|  | ||||
|     IDescription IDescription.GetDisplayNames() | ||||
|     { | ||||
|         Description result = GetDisplayNames(); | ||||
|         return result; | ||||
|     } | ||||
|  | ||||
|     List<string> IDescription.GetParameterNames() | ||||
|     { | ||||
|         List<string> results = new() | ||||
|         { | ||||
|             nameof(Engineer), | ||||
|             nameof(EquipId), | ||||
|             nameof(FileName), | ||||
|             nameof(HeaderUniqueId), | ||||
|             nameof(Id), | ||||
|             nameof(Layer), | ||||
|             nameof(RDS), | ||||
|             nameof(Run), | ||||
|             nameof(UniqueId), | ||||
|             nameof(Zone), | ||||
|             nameof(SheetRhoVariation), | ||||
|         }; | ||||
|         return results; | ||||
|     } | ||||
|  | ||||
|     JsonProperty[] IDescription.GetDefault(IFileRead fileRead, Logistics logistics) | ||||
|     { | ||||
|         JsonProperty[] results; | ||||
|         IDescription description = GetDefault(fileRead, logistics); | ||||
|         string json = JsonSerializer.Serialize(description, description.GetType()); | ||||
|         object @object = JsonSerializer.Deserialize<object>(json); | ||||
|         results = ((JsonElement)@object).EnumerateObject().ToArray(); | ||||
|         return results; | ||||
|     } | ||||
|  | ||||
|     List<string> IDescription.GetPairedParameterNames() | ||||
|     { | ||||
|         List<string> results = new(); | ||||
|         return results; | ||||
|     } | ||||
|  | ||||
|     List<string> IDescription.GetIgnoreParameterNames(Test test) | ||||
|     { | ||||
|         List<string> results = new(); | ||||
|         return results; | ||||
|     } | ||||
|  | ||||
|     IDescription IDescription.GetDefaultDescription(IFileRead fileRead, Logistics logistics) | ||||
|     { | ||||
|         Description result = GetDefault(fileRead, logistics); | ||||
|         return result; | ||||
|     } | ||||
|  | ||||
|     Dictionary<string, string> IDescription.GetDisplayNamesJsonElement(IFileRead fileRead) | ||||
|     { | ||||
|         Dictionary<string, string> results = new(); | ||||
|         IDescription description = GetDisplayNames(); | ||||
|         string json = JsonSerializer.Serialize(description, description.GetType()); | ||||
|         JsonElement jsonElement = JsonSerializer.Deserialize<JsonElement>(json); | ||||
|         foreach (JsonProperty jsonProperty in jsonElement.EnumerateObject()) | ||||
|         { | ||||
|             if (!results.ContainsKey(jsonProperty.Name)) | ||||
|                 results.Add(jsonProperty.Name, string.Empty); | ||||
|             if (jsonProperty.Value is JsonElement jsonPropertyValue) | ||||
|                 results[jsonProperty.Name] = jsonPropertyValue.ToString(); | ||||
|         } | ||||
|         return results; | ||||
|     } | ||||
|  | ||||
|     List<IDescription> IDescription.GetDescriptions(IFileRead fileRead, Logistics logistics, List<Test> tests, IProcessData iProcessData) | ||||
|     { | ||||
|         List<IDescription> results = new(); | ||||
|         if (iProcessData is null || iProcessData.Details.Count == 0 || iProcessData is not ProcessData processData) | ||||
|             results.Add(GetDefault(fileRead, logistics)); | ||||
|         else | ||||
|         { | ||||
|             string nullData; | ||||
|             Description description; | ||||
|             object configDataNullData = fileRead.NullData; | ||||
|             if (configDataNullData is null) | ||||
|                 nullData = string.Empty; | ||||
|             else | ||||
|                 nullData = configDataNullData.ToString(); | ||||
|             for (int i = 0; i < iProcessData.Details.Count; i++) | ||||
|             { | ||||
|                 if (iProcessData.Details[i] is not Detail detail) | ||||
|                     continue; | ||||
|                 description = new Description | ||||
|                 { | ||||
|                     Test = (int)tests[i], | ||||
|                     Count = tests.Count, | ||||
|                     Index = i, | ||||
|                     // | ||||
|                     EventName = fileRead.EventName, | ||||
|                     NullData = nullData, | ||||
|                     JobID = fileRead.CellInstanceName, | ||||
|                     Sequence = logistics.Sequence.ToString(), | ||||
|                     MesEntity = logistics.MesEntity, | ||||
|                     ReportFullPath = logistics.ReportFullPath, | ||||
|                     ProcessJobID = logistics.ProcessJobID, | ||||
|                     MID = logistics.MID, | ||||
|                     // | ||||
|                     Date = processData.Date.ToString(GetDateFormat()), | ||||
|                     Employee = processData.Employee, | ||||
|                     Lot = processData.Lot, | ||||
|                     PSN = processData.PSN, | ||||
|                     Reactor = processData.Reactor, | ||||
|                     Recipe = processData.Recipe, | ||||
|                     // | ||||
|                     AutoOptimizeGain = processData.AutoOptimizeGain, | ||||
|                     AutoProbeHeightSet = processData.AutoProbeHeightSet, | ||||
|                     Avg = processData.Avg, | ||||
|                     DataReject = processData.DataReject, | ||||
|                     DLRatio = processData.DLRatio, | ||||
|                     Merit = detail.Merit, | ||||
|                     Pt = detail.Pt, | ||||
|                     R = detail.R, | ||||
|                     ResistivitySpec = processData.ResistivitySpec, | ||||
|                     Rs = detail.Rs, | ||||
|                     SemiRadial = processData.SemiRadial, | ||||
|                     StdDev = processData.StdDev, | ||||
|                     T = detail.T, | ||||
|                     Temp = processData.Temp, | ||||
|                     // | ||||
|                     Engineer = processData.Engineer, | ||||
|                     EquipId = processData.EquipId, | ||||
|                     FileName = processData.FileName, | ||||
|                     HeaderUniqueId = detail.HeaderUniqueId, | ||||
|                     Id = processData.UniqueId, | ||||
|                     Layer = processData.Layer, | ||||
|                     RDS = processData.RDS, | ||||
|                     Run = processData.Run, | ||||
|                     UniqueId = detail.UniqueId, | ||||
|                     Zone = processData.Zone, | ||||
|                     // | ||||
|                     SheetRhoVariation = string.Empty, | ||||
|                 }; | ||||
|                 results.Add(description); | ||||
|             } | ||||
|         } | ||||
|         return results; | ||||
|     } | ||||
|  | ||||
|     private static Description GetDisplayNames() | ||||
|     { | ||||
|         Description result = new(); | ||||
|         return result; | ||||
|     } | ||||
|  | ||||
|     private Description GetDefault(IFileRead fileRead, Logistics logistics) | ||||
|     { | ||||
|         Description result = new() | ||||
|         { | ||||
|             Test = -1, | ||||
|             Count = 0, | ||||
|             Index = -1, | ||||
|             // | ||||
|             EventName = fileRead.EventName, | ||||
|             NullData = fileRead.NullData, | ||||
|             JobID = fileRead.CellInstanceName, | ||||
|             Sequence = logistics.Sequence.ToString(), | ||||
|             MesEntity = fileRead.MesEntity, | ||||
|             ReportFullPath = logistics.ReportFullPath, | ||||
|             ProcessJobID = logistics.ProcessJobID, | ||||
|             MID = logistics.MID, | ||||
|             // | ||||
|             Date = nameof(Date), | ||||
|             Employee = nameof(Employee), | ||||
|             Lot = nameof(Lot), | ||||
|             PSN = nameof(PSN), | ||||
|             Reactor = nameof(Reactor), | ||||
|             Recipe = nameof(Recipe), | ||||
|             // | ||||
|             AutoOptimizeGain = nameof(AutoOptimizeGain), | ||||
|             AutoProbeHeightSet = nameof(AutoProbeHeightSet), | ||||
|             Avg = nameof(Avg), | ||||
|             DataReject = nameof(DataReject), | ||||
|             DLRatio = nameof(DLRatio), | ||||
|             Merit = nameof(Merit), | ||||
|             Pt = nameof(Pt), | ||||
|             R = nameof(R), | ||||
|             ResistivitySpec = nameof(ResistivitySpec), | ||||
|             Rs = nameof(Rs), | ||||
|             SemiRadial = nameof(SemiRadial), | ||||
|             StdDev = nameof(StdDev), | ||||
|             T = nameof(T), | ||||
|             Temp = nameof(Temp), | ||||
|             // | ||||
|             Engineer = nameof(Engineer), | ||||
|             EquipId = nameof(EquipId), | ||||
|             FileName = nameof(FileName), | ||||
|             HeaderUniqueId = nameof(HeaderUniqueId), | ||||
|             Id = nameof(Id), | ||||
|             Layer = nameof(Layer), | ||||
|             RDS = nameof(RDS), | ||||
|             Run = nameof(Run), | ||||
|             UniqueId = nameof(UniqueId), | ||||
|             Zone = nameof(Zone), | ||||
|             SheetRhoVariation = nameof(SheetRhoVariation), | ||||
|         }; | ||||
|         return result; | ||||
|     } | ||||
|  | ||||
|     internal static string GetDateFormat() => "MM/dd/yyyy hh:mm:ss tt"; | ||||
|  | ||||
| } | ||||
| @ -1,27 +0,0 @@ | ||||
| namespace Adaptation.FileHandlers.txt; | ||||
|  | ||||
| public class Descriptor | ||||
| { | ||||
|  | ||||
|     public string Employee { get; private set; } | ||||
|     public string Layer { get; private set; } | ||||
|     public string PSN { get; private set; } | ||||
|     public string RDS { get; private set; } | ||||
|     public string Reactor { get; private set; } | ||||
|     public string Run { get; private set; } | ||||
|     public string Title { get; private set; } | ||||
|     public string Zone { get; private set; } | ||||
|  | ||||
|     public Descriptor(string employee, string layer, string psn, string rds, string reactor, string run, string title, string zone) | ||||
|     { | ||||
|         Employee = employee; | ||||
|         Layer = layer; | ||||
|         PSN = psn; | ||||
|         RDS = rds; | ||||
|         Reactor = reactor; | ||||
|         Run = run; | ||||
|         Title = title; | ||||
|         Zone = zone; | ||||
|     } | ||||
|  | ||||
| } | ||||
| @ -1,16 +0,0 @@ | ||||
| namespace Adaptation.FileHandlers.txt; | ||||
|  | ||||
| public class Detail | ||||
| { | ||||
|  | ||||
|     public string HeaderUniqueId { get; set; } | ||||
|     public string Merit { get; set; } | ||||
|     public string Pt { get; set; } | ||||
|     public string R { get; set; } | ||||
|     public string Rs { get; set; } | ||||
|     public string T { get; set; } | ||||
|     public string UniqueId { get; set; } | ||||
|  | ||||
|     public override string ToString() => string.Concat(Merit, ";", Pt, ";", R, ";", Rs, ";", T); | ||||
|  | ||||
| } | ||||
| @ -1,131 +0,0 @@ | ||||
| using Adaptation.Eaf.Management.ConfigurationData.CellAutomation; | ||||
| using Adaptation.Ifx.Eaf.EquipmentConnector.File.Configuration; | ||||
| using Adaptation.Shared; | ||||
| using Adaptation.Shared.Methods; | ||||
| using System; | ||||
| using System.Collections.Generic; | ||||
| using System.IO; | ||||
| using System.Text.Json; | ||||
| using System.Text.RegularExpressions; | ||||
|  | ||||
| namespace Adaptation.FileHandlers.txt; | ||||
|  | ||||
| public class FileRead : Shared.FileRead, IFileRead | ||||
| { | ||||
|  | ||||
|     private long? _TickOffset; | ||||
|  | ||||
|     public FileRead(ISMTP smtp, Dictionary<string, string> fileParameter, string cellInstanceName, int? connectionCount, string cellInstanceConnectionName, FileConnectorConfiguration fileConnectorConfiguration, string equipmentTypeName, string parameterizedModelObjectDefinitionType, IList<ModelObjectParameterDefinition> modelObjectParameters, string equipmentDictionaryName, Dictionary<string, List<long>> dummyRuns, Dictionary<long, List<string>> staticRuns, bool useCyclicalForDescription, bool isEAFHosted) : | ||||
|         base(new Description(), true, smtp, fileParameter, cellInstanceName, connectionCount, cellInstanceConnectionName, fileConnectorConfiguration, equipmentTypeName, parameterizedModelObjectDefinitionType, modelObjectParameters, equipmentDictionaryName, dummyRuns, staticRuns, useCyclicalForDescription, isEAFHosted: connectionCount is null) | ||||
|     { | ||||
|         _MinFileLength = 15; | ||||
|         _NullData = string.Empty; | ||||
|         _Logistics = new(this); | ||||
|         if (_FileParameter is null) | ||||
|             throw new Exception(cellInstanceConnectionName); | ||||
|         if (_ModelObjectParameterDefinitions is null) | ||||
|             throw new Exception(cellInstanceConnectionName); | ||||
|         if (_IsDuplicator) | ||||
|             throw new Exception(cellInstanceConnectionName); | ||||
|         if (_IsEAFHosted) | ||||
|             NestExistingFiles(_FileConnectorConfiguration); | ||||
|     } | ||||
|  | ||||
|     void IFileRead.Move(Tuple<string, Test[], JsonElement[], List<FileInfo>> extractResults, Exception exception) => Move(extractResults); | ||||
|  | ||||
|     void IFileRead.WaitForThread() => WaitForThread(thread: null, threadExceptions: null); | ||||
|  | ||||
|     string IFileRead.GetEventDescription() | ||||
|     { | ||||
|         string result = _Description.GetEventDescription(); | ||||
|         return result; | ||||
|     } | ||||
|  | ||||
|     List<string> IFileRead.GetHeaderNames() | ||||
|     { | ||||
|         List<string> results = _Description.GetHeaderNames(); | ||||
|         return results; | ||||
|     } | ||||
|  | ||||
|     string[] IFileRead.Move(Tuple<string, Test[], JsonElement[], List<FileInfo>> extractResults, string to, string from, string resolvedFileLocation, Exception exception) | ||||
|     { | ||||
|         string[] results = Move(extractResults, to, from, resolvedFileLocation, exception); | ||||
|         return results; | ||||
|     } | ||||
|  | ||||
|     JsonProperty[] IFileRead.GetDefault() | ||||
|     { | ||||
|         JsonProperty[] results = _Description.GetDefault(this, _Logistics); | ||||
|         return results; | ||||
|     } | ||||
|  | ||||
|     Dictionary<string, string> IFileRead.GetDisplayNamesJsonElement() | ||||
|     { | ||||
|         Dictionary<string, string> results = _Description.GetDisplayNamesJsonElement(this); | ||||
|         return results; | ||||
|     } | ||||
|  | ||||
|     List<IDescription> IFileRead.GetDescriptions(IFileRead fileRead, List<Test> tests, IProcessData processData) | ||||
|     { | ||||
|         List<IDescription> results = _Description.GetDescriptions(fileRead, _Logistics, tests, processData); | ||||
|         return results; | ||||
|     } | ||||
|  | ||||
|     Tuple<string, Test[], JsonElement[], List<FileInfo>> IFileRead.GetExtractResult(string reportFullPath, string eventName) | ||||
|     { | ||||
|         Tuple<string, Test[], JsonElement[], List<FileInfo>> results; | ||||
|         if (string.IsNullOrEmpty(eventName)) | ||||
|             throw new Exception(); | ||||
|         _ReportFullPath = reportFullPath; | ||||
|         DateTime dateTime = DateTime.Now; | ||||
|         results = GetExtractResult(reportFullPath, dateTime); | ||||
|         if (results.Item3 is null) | ||||
|             results = new Tuple<string, Test[], JsonElement[], List<FileInfo>>(results.Item1, Array.Empty<Test>(), JsonSerializer.Deserialize<JsonElement[]>("[]"), results.Item4); | ||||
|         if (results.Item3.Length > 0 && _IsEAFHosted) | ||||
|             WritePDSF(this, results.Item3); | ||||
|         UpdateLastTicksDuration(DateTime.Now.Ticks - dateTime.Ticks); | ||||
|         return results; | ||||
|     } | ||||
|  | ||||
|     Tuple<string, Test[], JsonElement[], List<FileInfo>> IFileRead.ReExtract() | ||||
|     { | ||||
|         Tuple<string, Test[], JsonElement[], List<FileInfo>> results; | ||||
|         List<string> headerNames = _Description.GetHeaderNames(); | ||||
|         Dictionary<string, string> keyValuePairs = _Description.GetDisplayNamesJsonElement(this); | ||||
|         results = ReExtract(this, headerNames, keyValuePairs); | ||||
|         return results; | ||||
|     } | ||||
|  | ||||
|     private Tuple<string, Test[], JsonElement[], List<FileInfo>> GetExtractResult(string reportFullPath, DateTime dateTime) | ||||
|     { | ||||
|         Tuple<string, Test[], JsonElement[], List<FileInfo>> results = new(string.Empty, null, null, new List<FileInfo>()); | ||||
|         _TickOffset ??= 0; // new FileInfo(reportFullPath).LastWriteTime.Ticks - dateTime.Ticks; | ||||
|         _Logistics = new Logistics(this, _TickOffset.Value, reportFullPath, useSplitForMID: true); | ||||
|         SetFileParameterLotIDToLogisticsMID(); | ||||
|         if (_Logistics.FileInfo.Length < _MinFileLength) | ||||
|             results.Item4.Add(_Logistics.FileInfo); | ||||
|         else | ||||
|         { | ||||
|             IProcessData iProcessData = new ProcessData(this, _Logistics, results.Item4); | ||||
|             if (iProcessData is not ProcessData processData) | ||||
|                 throw new Exception(string.Concat("A) No Data - ", dateTime.Ticks)); | ||||
|             string mid; | ||||
|             if (!string.IsNullOrEmpty(processData.Run) && string.IsNullOrEmpty(processData.Reactor) && string.IsNullOrEmpty(processData.RDS) && string.IsNullOrEmpty(processData.PSN)) | ||||
|                 mid = processData.Run; | ||||
|             else if (!string.IsNullOrEmpty(processData.Employee) && string.IsNullOrEmpty(processData.Reactor) && string.IsNullOrEmpty(processData.RDS) && string.IsNullOrEmpty(processData.PSN)) | ||||
|                 mid = processData.Employee; | ||||
|             else | ||||
|             { | ||||
|                 mid = string.Concat(processData.Reactor, "-", processData.RDS, "-", processData.PSN); | ||||
|                 mid = Regex.Replace(mid, @"[\\,\/,\:,\*,\?,\"",\<,\>,\|]", "_").Split('\r')[0].Split('\n')[0]; | ||||
|             } | ||||
|             SetFileParameterLotID(mid); | ||||
|             _Logistics.Update(mid, processData.Reactor); | ||||
|             if (iProcessData.Details.Count == 0) | ||||
|                 throw new Exception(string.Concat("B) No Data - ", dateTime.Ticks)); | ||||
|             results = iProcessData.GetResults(this, _Logistics, results.Item4); | ||||
|         } | ||||
|         return results; | ||||
|     } | ||||
|  | ||||
| } | ||||
| @ -1,593 +0,0 @@ | ||||
| using Adaptation.Shared; | ||||
| using Adaptation.Shared.Methods; | ||||
| using log4net; | ||||
| using System; | ||||
| using System.Collections.Generic; | ||||
| using System.Data; | ||||
| using System.Globalization; | ||||
| using System.IO; | ||||
| using System.Linq; | ||||
| using System.Text; | ||||
| using System.Text.Json; | ||||
| using System.Text.Json.Serialization; | ||||
| using System.Text.RegularExpressions; | ||||
|  | ||||
| namespace Adaptation.FileHandlers.txt; | ||||
|  | ||||
| public class ProcessData : IProcessData | ||||
| { | ||||
|  | ||||
|     private int _I; | ||||
|     private string _Data; | ||||
|  | ||||
|     private readonly ILog _Log; | ||||
|     private readonly List<object> _Details; | ||||
|  | ||||
|     public string JobID { get; set; } | ||||
|     public string MesEntity { get; set; } | ||||
|     public string AutoOptimizeGain { get; set; } | ||||
|     public string AutoProbeHeightSet { get; set; } | ||||
|     public string Avg { get; set; } | ||||
|     public string DLRatio { get; set; } | ||||
|     public string DataReject { get; set; } | ||||
|     public DateTime Date { get; set; } | ||||
|     public string Employee { get; set; } | ||||
|     public string Engineer { get; set; } | ||||
|     public string EquipId { get; set; } | ||||
|     public string FileName { get; set; } | ||||
|     public string Layer { get; set; } | ||||
|     public string Lot { get; set; } | ||||
|     public string PSN { get; set; } | ||||
|     public string RDS { get; set; } | ||||
|     public string Reactor { get; set; } | ||||
|     public string Recipe { get; set; } | ||||
|     public string ResistivitySpec { get; set; } | ||||
|     public string Run { get; set; } | ||||
|     public string SemiRadial { get; set; } | ||||
|     public string StdDev { get; set; } | ||||
|     public string Temp { get; set; } | ||||
|     public string UniqueId { get; set; } | ||||
|     public string Zone { get; set; } | ||||
|  | ||||
|     List<object> Shared.Properties.IProcessData.Details => _Details; | ||||
|  | ||||
|     public ProcessData(IFileRead fileRead, Logistics logistics, List<FileInfo> fileInfoCollection) | ||||
|     { | ||||
|         fileInfoCollection.Clear(); | ||||
|         _Details = new List<object>(); | ||||
|         _I = 0; | ||||
|         _Data = string.Empty; | ||||
|         JobID = logistics.JobID; | ||||
|         MesEntity = logistics.MesEntity; | ||||
|         _Log = LogManager.GetLogger(typeof(ProcessData)); | ||||
|         Parse(fileRead, logistics, fileInfoCollection); | ||||
|     } | ||||
|  | ||||
|     string IProcessData.GetCurrentReactor(IFileRead fileRead, Logistics logistics, Dictionary<string, string> reactors) => throw new Exception(string.Concat("See ", nameof(Parse))); | ||||
|  | ||||
|     Tuple<string, Test[], JsonElement[], List<FileInfo>> IProcessData.GetResults(IFileRead fileRead, Logistics logistics, List<FileInfo> fileInfoCollection) | ||||
|     { | ||||
|         Tuple<string, Test[], JsonElement[], List<FileInfo>> results; | ||||
|         List<Test> tests = new(); | ||||
|         foreach (object item in _Details) | ||||
|             tests.Add(Test.CDE); | ||||
|         List<IDescription> descriptions = fileRead.GetDescriptions(fileRead, tests, this); | ||||
|         if (tests.Count != descriptions.Count) | ||||
|             throw new Exception(); | ||||
|         for (int i = 0; i < tests.Count; i++) | ||||
|         { | ||||
|             if (descriptions[i] is not Description description) | ||||
|                 throw new Exception(); | ||||
|             if (description.Test != (int)tests[i]) | ||||
|                 throw new Exception(); | ||||
|         } | ||||
|         List<Description> fileReadDescriptions = (from l in descriptions select (Description)l).ToList(); | ||||
|         string json = JsonSerializer.Serialize(fileReadDescriptions, fileReadDescriptions.GetType()); | ||||
|         JsonElement[] jsonElements = JsonSerializer.Deserialize<JsonElement[]>(json); | ||||
|         results = new Tuple<string, Test[], JsonElement[], List<FileInfo>>(logistics.Logistics1[0], tests.ToArray(), jsonElements, fileInfoCollection); | ||||
|         return results; | ||||
|     } | ||||
|  | ||||
|     private string GetBefore(string text) | ||||
|     { | ||||
|         string str; | ||||
|         string str1; | ||||
|         int num = _Data.IndexOf(text, _I); | ||||
|         if (num <= -1) | ||||
|         { | ||||
|             str = _Data.Substring(_I); | ||||
|             _I = _Data.Length; | ||||
|             str1 = str.Trim(); | ||||
|         } | ||||
|         else | ||||
|         { | ||||
|             str = _Data.Substring(_I, num - _I); | ||||
|             _I = num + text.Length; | ||||
|             str1 = str.Trim(); | ||||
|         } | ||||
|         return str1; | ||||
|     } | ||||
|  | ||||
|     private string GetBefore(string text, bool trim) | ||||
|     { | ||||
|         string str; | ||||
|         string before; | ||||
|         if (!trim) | ||||
|         { | ||||
|             int num = _Data.IndexOf(text, _I); | ||||
|             if (num <= -1) | ||||
|             { | ||||
|                 str = _Data.Substring(_I); | ||||
|                 _I = _Data.Length; | ||||
|                 before = str; | ||||
|             } | ||||
|             else | ||||
|             { | ||||
|                 str = _Data.Substring(_I, num - _I); | ||||
|                 _I = num + text.Length; | ||||
|                 before = str; | ||||
|             } | ||||
|         } | ||||
|         else | ||||
|         { | ||||
|             before = GetBefore(text); | ||||
|         } | ||||
|         return before; | ||||
|     } | ||||
|  | ||||
|     private string GetToEOL() => GetBefore("\n"); | ||||
|  | ||||
|     private string GetToEOL(bool trim) | ||||
|     { | ||||
|         string str; | ||||
|         str = !trim ? GetBefore("\n", false) : GetToEOL(); | ||||
|         return str; | ||||
|     } | ||||
|  | ||||
|     private string GetToken() | ||||
|     { | ||||
|         while (true) | ||||
|         { | ||||
|             if (_I >= _Data.Length || !IsNullOrWhiteSpace(_Data.Substring(_I, 1))) | ||||
|                 break; | ||||
|             _I++; | ||||
|         } | ||||
|         int num = _I; | ||||
|         while (true) | ||||
|         { | ||||
|             if (num >= _Data.Length || IsNullOrWhiteSpace(_Data.Substring(num, 1))) | ||||
|                 break; | ||||
|             num++; | ||||
|         } | ||||
|         string str = _Data.Substring(_I, num - _I); | ||||
|         _I = num; | ||||
|         return str.Trim(); | ||||
|     } | ||||
|  | ||||
|     private string GetToText(string text) | ||||
|     { | ||||
|         string str = _Data.Substring(_I, _Data.IndexOf(text, _I) - _I).Trim(); | ||||
|         return str; | ||||
|     } | ||||
|  | ||||
|     private bool IsBlankLine() | ||||
|     { | ||||
|         int num = _Data.IndexOf("\n", _I); | ||||
|         return IsNullOrWhiteSpace(num > -1 ? _Data.Substring(_I, num - _I) : _Data.Substring(_I)); | ||||
|     } | ||||
|  | ||||
|     private static bool IsNullOrWhiteSpace(string text) | ||||
|     { | ||||
|         bool flag; | ||||
|         int num = 0; | ||||
|         while (true) | ||||
|         { | ||||
|             if (num >= text.Length) | ||||
|             { | ||||
|                 flag = true; | ||||
|                 break; | ||||
|             } | ||||
|             else if (char.IsWhiteSpace(text[num])) | ||||
|             { | ||||
|                 num++; | ||||
|             } | ||||
|             else | ||||
|             { | ||||
|                 flag = false; | ||||
|                 break; | ||||
|             } | ||||
|         } | ||||
|         return flag; | ||||
|     } | ||||
|  | ||||
|     private string PeekNextLine() | ||||
|     { | ||||
|         int num = _I; | ||||
|         string toEOL = GetToEOL(); | ||||
|         _I = num; | ||||
|         return toEOL; | ||||
|     } | ||||
|  | ||||
|     private void ScanPast(string text) | ||||
|     { | ||||
|         int num = _Data.IndexOf(text, _I); | ||||
|         if (num <= -1) | ||||
|         { | ||||
|             _I = _Data.Length; | ||||
|         } | ||||
|         else | ||||
|         { | ||||
|             _I = num + text.Length; | ||||
|         } | ||||
|     } | ||||
|  | ||||
|     internal static DateTime GetDateTime(Logistics logistics, string dateTimeText) | ||||
|     { | ||||
|         DateTime result; | ||||
|         string inputDateFormat = "HH:mm MM/dd/yy"; | ||||
|         if (dateTimeText.Length != inputDateFormat.Length) | ||||
|             result = logistics.DateTimeFromSequence; | ||||
|         else | ||||
|         { | ||||
|             if (!DateTime.TryParseExact(dateTimeText, inputDateFormat, CultureInfo.InvariantCulture, DateTimeStyles.None, out DateTime dateTimeParsed)) | ||||
|                 result = logistics.DateTimeFromSequence; | ||||
|             else | ||||
|             { | ||||
|                 if (dateTimeParsed < logistics.DateTimeFromSequence.AddDays(1) && dateTimeParsed > logistics.DateTimeFromSequence.AddDays(-1)) | ||||
|                     result = dateTimeParsed; | ||||
|                 else | ||||
|                     result = logistics.DateTimeFromSequence; | ||||
|             } | ||||
|         } | ||||
|         return result; | ||||
|     } | ||||
|  | ||||
|     private static (string, string) GetReactorAndRDS(string defaultReactor, string defaultRDS, string text, string formattedText, string[] segments) | ||||
|     { | ||||
|         string rds; | ||||
|         string reactor; | ||||
|         if (string.IsNullOrEmpty(text) || segments.Length == 0 || string.IsNullOrEmpty(formattedText)) | ||||
|             reactor = defaultReactor; | ||||
|         else | ||||
|             reactor = segments[0]; | ||||
|         if (segments.Length <= 1 || !int.TryParse(segments[1], out int rdsValue) || rdsValue < 99) | ||||
|             rds = defaultRDS; | ||||
|         else | ||||
|             rds = segments[1]; | ||||
|         if (reactor.Length > 3) | ||||
|         { | ||||
|             rds = reactor; | ||||
|             reactor = defaultReactor; | ||||
|         } | ||||
|         return new(reactor, rds); | ||||
|     } | ||||
|  | ||||
|     private static (string, string) GetLayerAndPSN(string defaultLayer, string defaultPSN, string[] segments) | ||||
|     { | ||||
|         string psn; | ||||
|         string layer; | ||||
|         if (segments.Length <= 2) | ||||
|         { | ||||
|             psn = defaultPSN; | ||||
|             layer = defaultLayer; | ||||
|         } | ||||
|         else | ||||
|         { | ||||
|             string[] segmentsB = segments[2].Split('.'); | ||||
|             psn = segmentsB[0]; | ||||
|             if (segmentsB.Length <= 1) | ||||
|                 layer = defaultLayer; | ||||
|             else | ||||
|             { | ||||
|                 layer = segmentsB[1]; | ||||
|                 if (layer.Length > 1 && layer[0] == '0') | ||||
|                     layer = layer.Substring(1); | ||||
|             } | ||||
|         } | ||||
|         return (layer, psn); | ||||
|     } | ||||
|  | ||||
|     private static string GetZone(string[] segments) | ||||
|     { | ||||
|         string result; | ||||
|         if (segments.Length <= 3) | ||||
|             result = string.Empty; | ||||
|         else | ||||
|         { | ||||
|             result = segments[3]; | ||||
|             if (result.Length > 1 && result[0] == '0') | ||||
|                 result = result.Substring(1); | ||||
|         } | ||||
|         return result; | ||||
|     } | ||||
|  | ||||
|     public static Descriptor GetDescriptor(string text) | ||||
|     { | ||||
|         Descriptor result; | ||||
|         string psn; | ||||
|         string rds; | ||||
|         string run; | ||||
|         string zone; | ||||
|         string layer; | ||||
|         string title; | ||||
|         string reactor; | ||||
|         string employee; | ||||
|         string defaultPSN = string.Empty; | ||||
|         string defaultRDS = string.Empty; | ||||
|         string defaultZone = string.Empty; | ||||
|         string defaultLayer = string.Empty; | ||||
|         string defaultReactor = string.Empty; | ||||
|         string defaultEmployee = string.Empty; | ||||
|         if (Regex.IsMatch(text, @"^[a-zA-z][0-9]{2,4}$")) | ||||
|         { | ||||
|             run = text.ToUpper(); | ||||
|             title = text; | ||||
|             psn = defaultPSN; | ||||
|             rds = defaultRDS; | ||||
|             zone = defaultZone; | ||||
|             layer = defaultLayer; | ||||
|             reactor = defaultReactor; | ||||
|             employee = defaultEmployee; | ||||
|         } | ||||
|         else if (string.IsNullOrEmpty(text) || (text.Length is 2 or 3 && Regex.IsMatch(text, "^[a-zA-z]{2,3}"))) | ||||
|         { | ||||
|             run = text; | ||||
|             title = text; | ||||
|             employee = text; | ||||
|             psn = defaultPSN; | ||||
|             rds = defaultRDS; | ||||
|             zone = defaultZone; | ||||
|             layer = defaultLayer; | ||||
|             reactor = defaultReactor; | ||||
|         } | ||||
|         else if (Regex.IsMatch(text, @"^[0-9]{2}[.][0-9]{1}[.]?[0-9]{0,1}")) | ||||
|         { | ||||
|             string[] segments = text.Split('.'); | ||||
|             run = text; | ||||
|             title = text; | ||||
|             psn = defaultPSN; | ||||
|             rds = defaultRDS; | ||||
|             layer = segments[1]; | ||||
|             reactor = segments[0]; | ||||
|             employee = defaultEmployee; | ||||
|             if (segments.Length <= 2) | ||||
|                 zone = defaultZone; | ||||
|             else | ||||
|                 zone = segments[2]; | ||||
|         } | ||||
|         else | ||||
|         { | ||||
|             // Remove illegal characters \/:*?"<>| found in the run. | ||||
|             title = Regex.Replace(text, @"[\\,\/,\:,\*,\?,\"",\<,\>,\|]", "_").Split('\r')[0].Split('\n')[0]; | ||||
|             if (title.Length > 2 && title[0] == '1' && (title[1] == 'T' || title[1] == 't')) | ||||
|                 title = title.Substring(2); | ||||
|             run = title; | ||||
|             string[] segments = title.Split('-'); | ||||
|             // bool hasRDS = Regex.IsMatch(title, "[-]?([QP][0-9]{4,}|[0-9]{5,})[-]?"); | ||||
|             (reactor, rds) = GetReactorAndRDS(defaultReactor, defaultRDS, text, title, segments); | ||||
|             (layer, psn) = GetLayerAndPSN(defaultLayer, defaultPSN, segments); | ||||
|             zone = GetZone(segments); | ||||
|             employee = defaultEmployee; | ||||
|         } | ||||
|         result = new(employee, layer, psn, rds, reactor, run, title, zone); | ||||
|         return result; | ||||
|     } | ||||
|  | ||||
|     private void Set(Logistics logistics, string receivedData) | ||||
|     { | ||||
|         string lot; | ||||
|         string psn; | ||||
|         string rds; | ||||
|         string run; | ||||
|         string temp; | ||||
|         string zone; | ||||
|         string layer; | ||||
|         string title; | ||||
|         DateTime date; | ||||
|         string recipe; | ||||
|         string dlRatio; | ||||
|         string equipId; | ||||
|         string reactor; | ||||
|         string employee; | ||||
|         string engineer; | ||||
|         string resistivitySpec; | ||||
|         ScanPast("RUN:"); | ||||
|         title = GetToEOL(); | ||||
|         ScanPast("Recipe:"); | ||||
|         recipe = GetBefore("RESISTIVITY SPEC:"); | ||||
|         if (string.IsNullOrEmpty(recipe)) | ||||
|         { | ||||
|             _I = 0; | ||||
|             _Data = receivedData; | ||||
|             ScanPast("RUN:"); | ||||
|             title = GetToEOL(); | ||||
|             ScanPast("DEVICE:"); | ||||
|             recipe = GetBefore("RESISTIVITY SPEC:"); | ||||
|         } | ||||
|         title = title.Trim(); | ||||
|         if (title[0] != '[' && title[title.Length - 1] != ']') | ||||
|             throw new Exception("Lot summary data is invalid or missing."); | ||||
|         title = title.Substring(1, title.Length - 2); | ||||
|         Descriptor descriptor = GetDescriptor(title); | ||||
|         psn = descriptor.PSN; | ||||
|         rds = descriptor.RDS; | ||||
|         run = descriptor.Run; | ||||
|         zone = descriptor.Zone; | ||||
|         layer = descriptor.Layer; | ||||
|         title = descriptor.Title; | ||||
|         reactor = descriptor.Reactor; | ||||
|         employee = descriptor.Employee; | ||||
|         resistivitySpec = GetToEOL(); | ||||
|         ScanPast("EQUIP#:"); | ||||
|         equipId = GetBefore("Engineer:"); | ||||
|         // Remove illegal characters \/:*?"<>| found in the equipId. | ||||
|         equipId = Regex.Replace(equipId, @"[\\,\/,\:,\*,\?,\"",\<,\>,\|]", "_").Split('\r')[0].Split('\n')[0]; | ||||
|         engineer = GetToEOL(); | ||||
|         ScanPast("LotID:"); | ||||
|         lot = GetBefore("D.L.RATIO:"); | ||||
|         dlRatio = GetToEOL(); | ||||
|         ScanPast("OPERATOR:"); | ||||
|         if (!string.IsNullOrEmpty(employee)) | ||||
|             _ = GetBefore("TEMP:"); | ||||
|         else | ||||
|             employee = GetBefore("TEMP:"); | ||||
|         temp = GetToken(); | ||||
|         string dateTimeText = GetToEOL(); | ||||
|         date = GetDateTime(logistics, dateTimeText); | ||||
|         //create filename / unique id | ||||
|         string timeFormat = "yyyyMMddHHmmss"; | ||||
|         _Log.Debug($"****ParseData - Title:{title}; EquipId:{equipId};"); | ||||
|         if (string.IsNullOrEmpty(title)) | ||||
|             throw new Exception("Batch (title) information does not exist"); | ||||
|         Lot = lot; | ||||
|         PSN = psn; | ||||
|         RDS = rds; | ||||
|         Run = run; | ||||
|         Date = date; | ||||
|         Temp = temp; | ||||
|         Zone = zone; | ||||
|         Layer = layer; | ||||
|         Recipe = recipe; | ||||
|         DLRatio = dlRatio; | ||||
|         Reactor = reactor; | ||||
|         Employee = employee; | ||||
|         Engineer = engineer; | ||||
|         ResistivitySpec = resistivitySpec; | ||||
|         UniqueId = string.Concat(equipId, "_", title, "_", logistics.DateTimeFromSequence.ToString(timeFormat)); | ||||
|     } | ||||
|  | ||||
|     private void Parse(IFileRead fileRead, Logistics logistics, List<FileInfo> fileInfoCollection) | ||||
|     { | ||||
|         if (fileRead is null) | ||||
|             throw new ArgumentNullException(nameof(fileRead)); | ||||
|         // Convert the source file to UTF8Encoding format and then back to string for processing.  This convertion | ||||
|         // shall eliminate the special HEX characters such as 0x18 "CANCEL" and 0x20 "SPACE" captured via nPort. | ||||
|         string rawText = File.ReadAllText(logistics.ReportFullPath); | ||||
|         UTF8Encoding utf8Encoding = new(); | ||||
|         byte[] bytes = utf8Encoding.GetBytes(rawText); | ||||
|         string convertedText = utf8Encoding.GetString(bytes); | ||||
|         // Replaces all control characters with a space, except for the TAB (0x09), LF (0x0A), CR (0x0D), and | ||||
|         // normal ASCII characters, which are valid characters for SharePoint. | ||||
|         string receivedData = Regex.Replace(convertedText, @"[^\u0009\u000A\u000D\u0020-\u007E]", " "); | ||||
|         string log = receivedData; | ||||
|         for (short i = 0; i < short.MaxValue; i++) | ||||
|         { | ||||
|             if (!log.Contains("   ")) | ||||
|                 break; | ||||
|             log = log.Replace("   ", "  "); | ||||
|         } | ||||
|         log = log.Replace("  ", "\t").Replace(": ", "\t").Replace(":\t", "\t"); | ||||
|         IEnumerable<string> lines = from l in log.Split('\r') select l.Trim(); | ||||
|         string logFile = Path.ChangeExtension(logistics.ReportFullPath, ".log"); | ||||
|         File.WriteAllLines(logFile, lines); | ||||
|         fileInfoCollection.Add(new FileInfo(logFile)); | ||||
|         //parse file | ||||
|         string h = string.Empty; | ||||
|         receivedData = receivedData.Replace("\r", "\n").Trim(); | ||||
|         _I = 0; | ||||
|         _Data = string.Empty; | ||||
|         if (string.IsNullOrEmpty(receivedData)) | ||||
|             throw new Exception("No data!"); | ||||
|         Detail detail; | ||||
|         _I = 0; | ||||
|         _Data = receivedData; | ||||
|         List<Detail> details = new(); | ||||
|         Set(logistics, receivedData); | ||||
|         ScanPast("AutoOptimizeGain ="); | ||||
|         AutoOptimizeGain = GetBefore("AutoProbeHeightSet ="); | ||||
|         AutoProbeHeightSet = GetToEOL(); | ||||
|         ScanPast("DataReject"); | ||||
|         DataReject = GetToEOL(); | ||||
|         _ = GetToEOL(); | ||||
|         FileName = GetToEOL(); | ||||
|         _ = GetToEOL(); | ||||
|         _ = GetToEOL(); | ||||
|         bool check = false; | ||||
|         while (!IsBlankLine()) | ||||
|         { | ||||
|             detail = new Detail() { Pt = GetToken() }; | ||||
|             if (detail.Pt.Contains("Avg")) | ||||
|                 break; | ||||
|             else if (!detail.Pt.Contains(':')) | ||||
|             { | ||||
|                 detail.R = GetToken(); | ||||
|                 detail.T = GetToken(); | ||||
|                 detail.Rs = GetToken(); | ||||
|                 detail.Merit = GetToken(); | ||||
|                 detail.UniqueId = string.Concat("_Point-", details.Count + 1); | ||||
|                 _ = GetToEOL(); | ||||
|                 details.Add(detail); | ||||
|             } | ||||
|             else | ||||
|             { | ||||
|                 check = true; | ||||
|                 break; | ||||
|             } | ||||
|         } | ||||
|         _I = 0; | ||||
|         _Data = receivedData; | ||||
|         if (!check) | ||||
|         { | ||||
|             ScanPast("Avg ="); | ||||
|             Avg = GetToken(); | ||||
|             StdDev = GetToken(); | ||||
|             ScanPast("SEMI Radial="); | ||||
|             SemiRadial = GetToEOL(); | ||||
|         } | ||||
|         else | ||||
|         { | ||||
|             ScanPast("RsAv "); | ||||
|             Avg = GetBefore("+/-"); | ||||
|             StdDev = GetToken(); | ||||
|             _Log.Debug($"****ProcessData - RsAv StDev={StdDev}"); | ||||
|             ScanPast("(Mx+Mn)"); | ||||
|             SemiRadial = GetToken(); | ||||
|             _Log.Debug($"****ProcessData - RsAv SemiRadial={SemiRadial}"); | ||||
|             _ = GetToEOL(); | ||||
|             int num = 0; | ||||
|             _ = GetBefore(": "); | ||||
|             for (string i = GetToken(); !string.IsNullOrEmpty(i); i = GetToken()) | ||||
|             { | ||||
|                 if (!i.Contains(':')) | ||||
|                 { | ||||
|                     detail = new Detail(); | ||||
|                     int num1 = num + 1; | ||||
|                     num = num1; | ||||
|                     _Log.Debug($"****ProcessData - RsAv Point={num1}"); | ||||
|                     detail.Pt = num1.ToString(); | ||||
|                     detail.Rs = i; | ||||
|                     detail.Merit = GetToken().Replace("|", ""); | ||||
|                     detail.UniqueId = string.Concat("_Point-", details.Count + 1); | ||||
|                     details.Add(detail); | ||||
|                 } | ||||
|             } | ||||
|         } | ||||
|         foreach (Detail item in details) | ||||
|         { | ||||
|             item.HeaderUniqueId = UniqueId; | ||||
|             item.UniqueId = string.Concat(item, item.UniqueId); | ||||
|         } | ||||
|         _Details.AddRange(details); | ||||
|         fileInfoCollection.Add(logistics.FileInfo); | ||||
|     } | ||||
|  | ||||
| #nullable enable | ||||
|  | ||||
|     internal static List<Description> GetDescriptions(JsonElement[] jsonElements) | ||||
|     { | ||||
|         List<Description> results = new(); | ||||
|         Description? description; | ||||
|         JsonSerializerOptions jsonSerializerOptions = new() { NumberHandling = JsonNumberHandling.AllowReadingFromString | JsonNumberHandling.WriteAsString }; | ||||
|         foreach (JsonElement jsonElement in jsonElements) | ||||
|         { | ||||
|             if (jsonElement.ValueKind != JsonValueKind.Object) | ||||
|                 throw new Exception(); | ||||
|             description = JsonSerializer.Deserialize<Description>(jsonElement.ToString(), jsonSerializerOptions); | ||||
|             if (description is null) | ||||
|                 continue; | ||||
|             results.Add(description); | ||||
|         } | ||||
|         return results; | ||||
|     } | ||||
|  | ||||
| } | ||||
| @ -1,190 +1 @@ | ||||
| trigger: | ||||
|   branches: | ||||
|     include: | ||||
|       - development | ||||
|   paths: | ||||
|     include: | ||||
|       - "Adaptation/*" | ||||
|  | ||||
| pool: | ||||
|   name: eaf | ||||
|   demands: MET08RESIMAPCDE-Development | ||||
|  | ||||
| steps: | ||||
|   - script: | | ||||
|       set coreVersion=net7.0 | ||||
|       echo %coreVersion% | ||||
|       echo ##vso[task.setvariable variable=CoreVersion;]%coreVersion% | ||||
|       echo $(CoreVersion) | ||||
|     displayName: CoreVersion | ||||
|  | ||||
|   - script: | | ||||
|       set configuration=Debug | ||||
|       echo %configuration% | ||||
|       echo ##vso[task.setvariable variable=Configuration;]%configuration% | ||||
|       echo $(Configuration) | ||||
|     displayName: Configuration | ||||
|  | ||||
|   - script: | | ||||
|       set nugetSource=https://artifactory.intra.infineon.com/artifactory/api/nuget/ngt-fi-package-main-vir/index.json;D:/vsts-agent-win-x64-2.210.1-eaf/nuget | ||||
|       echo %nugetSource% | ||||
|       echo ##vso[task.setvariable variable=NugetSource;]%nugetSource% | ||||
|       echo $(NugetSource) | ||||
|     displayName: NugetSource | ||||
|  | ||||
|   - script: | | ||||
|       set gitCommit=$(Build.SourceVersion) | ||||
|       set gitCommitSeven=%gitCommit:~0,7% | ||||
|       echo %gitCommitSeven% | ||||
|       echo ##vso[task.setvariable variable=GitCommitSeven;]%gitCommitSeven% | ||||
|       echo $(GitCommitSeven) | ||||
|     displayName: GitCommitSeven | ||||
|  | ||||
|   - script: | | ||||
|       echo $(Build.BuildId) | ||||
|       echo $(Build.Reason) | ||||
|       echo $(Build.Repository.Id) | ||||
|       echo $(Build.Repository.Name) | ||||
|       echo $(Build.SourceVersion) | ||||
|       echo $(CoreVersion) | ||||
|       echo $(Configuration) | ||||
|       echo $(NugetSource) | ||||
|       echo $(GitCommitSeven) | ||||
|       REM echo $(pipelinePassword) | ||||
|     displayName: "Echo Check" | ||||
|  | ||||
|   - script: '"C:\program files\dotnet\dotnet.exe" nuget locals all --clear' | ||||
|     displayName: "Nuget Clear" | ||||
|     enabled: false | ||||
|  | ||||
|   - script: | | ||||
|       "C:\program files\dotnet\dotnet.exe" user-secrets init | ||||
|       "C:\program files\dotnet\dotnet.exe" user-secrets set "BuildNumber" "$(Build.BuildId)" | ||||
|       "C:\program files\dotnet\dotnet.exe" user-secrets set "GitCommitSeven" "$(GitCommitSeven)" | ||||
|       "C:\program files\dotnet\dotnet.exe" user-secrets list | ||||
|     workingDirectory: Adaptation | ||||
|     displayName: "Safe storage of app secrets - Adaptation" | ||||
|  | ||||
|   - task: CopyFiles@2 | ||||
|     displayName: "Copy Files to: - GhostPCL" | ||||
|     inputs: | ||||
|       Contents: '*' | ||||
|       SourceFolder: '\\mesfs.infineon.com\EC_EAFRepository\Staging\DeploymentStorage\GhostPCL\gpcl6win64' | ||||
|       TargetFolder: 'Adaptation\bin\$(Configuration)\net6.0\win-x64' | ||||
|       OverWrite: true | ||||
|     enabled: false | ||||
|  | ||||
|   - task: CopyFiles@2 | ||||
|     displayName: "Copy Files to: - LincPDFC" | ||||
|     inputs: | ||||
|       Contents: '*' | ||||
|       SourceFolder: '\\mesfs.infineon.com\EC_EAFRepository\Staging\DeploymentStorage\LincPDFC\v2.6.6.21' | ||||
|       TargetFolder: 'Adaptation\bin\$(Configuration)\net6.0\win-x64' | ||||
|       OverWrite: true | ||||
|     enabled: false | ||||
|  | ||||
|   - task: CopyFiles@2 | ||||
|     displayName: "Copy Files to: - PDF-Text-Stripper" | ||||
|     inputs: | ||||
|       Contents: '*' | ||||
|       SourceFolder: '\\mesfs.infineon.com\EC_EAFRepository\Staging\DeploymentStorage\PDF-Text-Stripper\v4.8.0.1' | ||||
|       TargetFolder: 'Adaptation\bin\$(Configuration)\net6.0\win-x64' | ||||
|       OverWrite: true | ||||
|     enabled: false | ||||
|  | ||||
|   - script: '"C:\program files\dotnet\dotnet.exe" build --configuration $(Configuration) --source $(NugetSource)' | ||||
|     workingDirectory: Adaptation | ||||
|     displayName: "Core Build - Adaptation" | ||||
|  | ||||
|   - powershell: Get-ChildItem .\ -include TestResults -Recurse | foreach ($_) { remove-item $_.fullname -Force -Recurse } | ||||
|     workingDirectory: "$(System.DefaultWorkingDirectory)/../../../$(Build.Repository.Name)" | ||||
|     displayName: "PowerShell Script" | ||||
|     continueOnError: true | ||||
|  | ||||
|   - script: "dotnet test --configuration $(Configuration)" | ||||
|     workingDirectory: Adaptation | ||||
|     displayName: "Core Test" | ||||
|  | ||||
|   - script: 'move /y "$(System.DefaultWorkingDirectory)/../../../$(Build.Repository.Name)/05_TestResults/TestResults" $(System.DefaultWorkingDirectory)' | ||||
|     displayName: "Move Results" | ||||
|  | ||||
|   - script: '"C:\program files\dotnet\dotnet.exe" tool restore' | ||||
|     workingDirectory: Adaptation | ||||
|     displayName: "Tool Restore" | ||||
|     enabled: false | ||||
|  | ||||
|   - script: '"C:\program files\dotnet\dotnet.exe" ReportGenerator -reports:$(System.DefaultWorkingDirectory)/TestResults/**/coverage.cobertura.xml -targetDir:$(Build.ArtifactStagingDirectory)\Coverage -reportTypes:Html_Dark' | ||||
|     workingDirectory: Adaptation | ||||
|     displayName: "Report Generator" | ||||
|     enabled: false | ||||
|  | ||||
|   - task: PublishTestResults@2 | ||||
|     displayName: "Publish Test Results **/*.trx" | ||||
|     inputs: | ||||
|       testResultsFormat: VSTest | ||||
|       testResultsFiles: "**/*.trx" | ||||
|       testRunTitle: "$(GitCommitSeven)-$(Build.BuildId)-$(CoreVersion)-$(Configuration)-$(Build.Repository.Name)" | ||||
|       searchFolder: "$(System.DefaultWorkingDirectory)/TestResults" | ||||
|  | ||||
|   - task: PublishTestResults@2 | ||||
|     displayName: "Publish Test Results */coverage.cobertura.xml" | ||||
|     inputs: | ||||
|       testResultsFormat: VSTest | ||||
|       testResultsFiles: "*/coverage.cobertura.xml" | ||||
|       testRunTitle: "$(GitCommitSeven)-$(Build.BuildId)-$(CoreVersion)-$(Configuration)-$(Build.Repository.Name)" | ||||
|       searchFolder: "$(System.DefaultWorkingDirectory)/TestResults" | ||||
|  | ||||
|   - task: mspremier.CreateWorkItem.CreateWorkItem-task.CreateWorkItem@1 | ||||
|     displayName: "Create work item" | ||||
|     inputs: | ||||
|       teamProject: "Mesa_FI" | ||||
|       workItemType: Bug | ||||
|       title: $(GitCommitSeven)-$(Build.BuildId)-$(Build.Repository.Name)-$(Configuration) | ||||
|       assignedTo: "$(Build.RequestedForId)" | ||||
|     enabled: false | ||||
|  | ||||
|   - script: '"C:\program files\dotnet\dotnet.exe" publish --configuration $(Configuration) --runtime win-x64 --self-contained -o $(Build.ArtifactStagingDirectory)\Adaptation --source $(NugetSource)' | ||||
|     workingDirectory: Adaptation | ||||
|     displayName: "Core Publish" | ||||
|     enabled: false | ||||
|  | ||||
|   - script: '"C:/Program Files (x86)/Microsoft Visual Studio/2022/BuildTools/MSBuild/Current/Bin/MSBuild.exe" /target:Restore /detailedsummary /consoleloggerparameters:PerformanceSummary;ErrorsOnly; /property:Configuration=$(Configuration);TargetFrameworkVersion=v4.8 /p:RestoreSources="$(NugetSource)"' | ||||
|     displayName: "MSBuild Restore" | ||||
|  | ||||
|   - script: '"C:/Program Files (x86)/Microsoft Visual Studio/2022/BuildTools/MSBuild/Current/Bin/MSBuild.exe" /target:Build /detailedsummary /consoleloggerparameters:PerformanceSummary;ErrorsOnly; /property:Configuration=$(Configuration);TargetFrameworkVersion=v4.8' | ||||
|     displayName: MSBuild | ||||
|  | ||||
|   - script: 'echo $(Build.SourceVersion)-$(Build.BuildId)-$(Build.Repository.Name)>bin\$(Configuration)\$(Build.Repository.Name).txt' | ||||
|     displayName: "Commit Id" | ||||
|  | ||||
|   - task: CopyFiles@2 | ||||
|     displayName: 'Copy Files to: D:\Framework4.8' | ||||
|     inputs: | ||||
|       Contents: "*$(Build.Repository.Name)*" | ||||
|       SourceFolder: 'bin\$(Configuration)' | ||||
|       TargetFolder: 'D:\Framework4.8\$(GitCommitSeven)-$(Build.BuildId)-$(Build.Repository.Name)-$(Configuration)' | ||||
|       OverWrite: true | ||||
|     enabled: false | ||||
|  | ||||
|   - task: CopyFiles@2 | ||||
|     displayName: 'Copy Files to: Local D EAF Deployment Storage' | ||||
|     inputs: | ||||
|       Contents: "*$(Build.Repository.Name)*" | ||||
|       SourceFolder: 'bin\$(Configuration)' | ||||
|       TargetFolder: 'D:\EAF\EAF Deployment Storage\Adaptation_$(Build.Repository.Name)' | ||||
|       OverWrite: true | ||||
|     enabled: false | ||||
|  | ||||
|   - script: | | ||||
|       "C:\program files\dotnet\dotnet.exe" clean --configuration $(Configuration) | ||||
|     workingDirectory: Adaptation | ||||
|     displayName: "Core Clean - Tests" | ||||
|  | ||||
|   - script: | | ||||
|       "C:\program files\dotnet\dotnet.exe" clean --configuration $(Configuration) | ||||
|     workingDirectory: Adaptation | ||||
|     displayName: "Core Clean - Adaptation" | ||||
|  | ||||
|   - script: 'echo $(Build.SourceVersion)-$(Build.BuildId)>bin_x_x_\$(Configuration)\$(CoreVersion)\win-x64\$(Build.Repository.Name).txt' | ||||
|     displayName: "Force Fail" | ||||
|     enabled: false | ||||
| # dotnet nuget push --source https://tfs.intra.infineon.com/tfs/FactoryIntegration/fccf8303-9cf7-4788-a9e0-4042541503fa/_packaging/EAF-Mesa-Integration/nuget/v3/index.json --api-key az D:\vsts-agent-win-x64-2.210.1-eaf\nuget\infineon.mesa.pdf.text.stripper.4.8.0.1.nupkg | ||||
| @ -35,7 +35,7 @@ | ||||
|         <RuntimeHostConfigurationOption Include="AssemblyName" Value="MET08RESIMAPCDE" /> | ||||
|     </ItemGroup> | ||||
|     <ItemGroup> | ||||
|         <PackageReference Include="coverlet.collector" Version="6.0.2" /> | ||||
|         <PackageReference Include="coverlet.collector" Version="6.0.3" /> | ||||
|         <PackageReference Include="FFMpegCore" Version="5.1.0" /> | ||||
|         <PackageReference Include="IKVM.AWT.WinForms" Version="7.2.4630.5"><NoWarn>NU1701</NoWarn></PackageReference> | ||||
|         <PackageReference Include="IKVM.OpenJDK.Core" Version="7.2.4630.5"><NoWarn>NU1701</NoWarn></PackageReference> | ||||
| @ -44,41 +44,39 @@ | ||||
|         <PackageReference Include="IKVM.OpenJDK.Util" Version="7.2.4630.5"><NoWarn>NU1701</NoWarn></PackageReference> | ||||
|         <PackageReference Include="IKVM.OpenJDK.XML.API" Version="7.2.4630.5"><NoWarn>NU1701</NoWarn></PackageReference> | ||||
|         <PackageReference Include="IKVM.Runtime" Version="7.2.4630.5"><NoWarn>NU1701</NoWarn></PackageReference> | ||||
|         <PackageReference Include="Instances" Version="3.0.0" /> | ||||
|         <PackageReference Include="Microsoft.Extensions.Configuration.Binder" Version="8.0.2" /> | ||||
|         <PackageReference Include="Microsoft.Extensions.Configuration.CommandLine" Version="8.0.0" /> | ||||
|         <PackageReference Include="Microsoft.Extensions.Configuration.EnvironmentVariables" Version="8.0.0" /> | ||||
|         <PackageReference Include="Microsoft.Extensions.Configuration.FileExtensions" Version="8.0.1" /> | ||||
|         <PackageReference Include="Microsoft.Extensions.Configuration.json" Version="8.0.1" /> | ||||
|         <PackageReference Include="Microsoft.Extensions.Configuration" Version="8.0.0" /> | ||||
|         <PackageReference Include="Microsoft.Extensions.DependencyInjection" Version="8.0.1" /> | ||||
|         <PackageReference Include="Microsoft.Extensions.Logging.Console" Version="8.0.1" /> | ||||
|         <PackageReference Include="Microsoft.Extensions.Logging.Debug" Version="8.0.1" /> | ||||
|         <PackageReference Include="Microsoft.Extensions.Logging" Version="8.0.1" /> | ||||
|         <PackageReference Include="Microsoft.NET.Test.Sdk" Version="17.11.1" /> | ||||
|         <PackageReference Include="Microsoft.Win32.SystemEvents" Version="8.0.0" /> | ||||
|         <PackageReference Include="MSTest.TestAdapter" Version="3.6.1" /> | ||||
|         <PackageReference Include="MSTest.TestFramework" Version="3.6.1" /> | ||||
|         <PackageReference Include="Instances" Version="3.0.1" /> | ||||
|         <PackageReference Include="log4net" Version="3.0.3"></PackageReference> | ||||
|         <PackageReference Include="Microsoft.Extensions.Configuration.Binder" Version="9.0.0" /> | ||||
|         <PackageReference Include="Microsoft.Extensions.Configuration.CommandLine" Version="9.0.0" /> | ||||
|         <PackageReference Include="Microsoft.Extensions.Configuration.EnvironmentVariables" Version="9.0.0" /> | ||||
|         <PackageReference Include="Microsoft.Extensions.Configuration.FileExtensions" Version="9.0.0" /> | ||||
|         <PackageReference Include="Microsoft.Extensions.Configuration.json" Version="9.0.0" /> | ||||
|         <PackageReference Include="Microsoft.Extensions.Configuration" Version="9.0.0" /> | ||||
|         <PackageReference Include="Microsoft.Extensions.DependencyInjection" Version="9.0.0" /> | ||||
|         <PackageReference Include="Microsoft.Extensions.Logging.Console" Version="9.0.0" /> | ||||
|         <PackageReference Include="Microsoft.Extensions.Logging.Debug" Version="9.0.0" /> | ||||
|         <PackageReference Include="Microsoft.Extensions.Logging" Version="9.0.0" /> | ||||
|         <PackageReference Include="Microsoft.NET.Test.Sdk" Version="17.12.0" /> | ||||
|         <PackageReference Include="Microsoft.Win32.SystemEvents" Version="9.0.0" /> | ||||
|         <PackageReference Include="MSTest.TestAdapter" Version="3.7.0" /> | ||||
|         <PackageReference Include="MSTest.TestFramework" Version="3.7.0" /> | ||||
|         <PackageReference Include="Pdfbox" Version="1.1.1"><NoWarn>NU1701</NoWarn></PackageReference> | ||||
|         <PackageReference Include="RoboSharp" Version="1.5.3" /> | ||||
|         <PackageReference Include="System.Configuration.ConfigurationManager" Version="8.0.1" /> | ||||
|         <PackageReference Include="System.Data.OleDb" Version="8.0.1" /> | ||||
|         <PackageReference Include="RoboSharp" Version="1.6.0" /> | ||||
|         <PackageReference Include="System.Configuration.ConfigurationManager" Version="9.0.0" /> | ||||
|         <PackageReference Include="System.Data.OleDb" Version="9.0.0" /> | ||||
|         <PackageReference Include="System.Data.SqlClient" Version="4.8.6" /> | ||||
|         <PackageReference Include="System.Drawing.Common" Version="8.0.10" /> | ||||
|         <PackageReference Include="System.Text.Json" Version="8.0.5" /> | ||||
|         <PackageReference Include="Tesseract" Version="5.2.0" /> | ||||
|         <PackageReference Include="System.Drawing.Common" Version="9.0.0" /> | ||||
|         <PackageReference Include="System.Text.Json" Version="9.0.0" /> | ||||
|     </ItemGroup> | ||||
|     <ItemGroup> | ||||
|         <PackageReference Include="Infineon.Mesa.PDF.Text.Stripper" Version="4.8.0.2"><NoWarn>NU1701</NoWarn></PackageReference> | ||||
|     </ItemGroup> | ||||
|     <ItemGroup> | ||||
|         <PackageReference Include="Infineon.Yoda.DotNetCore" Version="5.4.3" /> | ||||
|         <PackageReference Include="Tibco.Rendezvous.DotNetCore" Version="8.5.0" /> | ||||
|         <PackageReference Include="Infineon.Yoda.DotNetCore" Version="5.4.1" /> | ||||
|     </ItemGroup> | ||||
|     <ItemGroup> | ||||
|         <PackageReference Include="Infineon.Mesa.PDF.Text.Stripper" Version="4.8.0.1"><NoWarn>NU1701</NoWarn></PackageReference> | ||||
|     </ItemGroup> | ||||
|     <ItemGroup> | ||||
|         <PackageReference Include="External.Common.Logging.Core" Version="3.3.1"><NoWarn>NU1701</NoWarn></PackageReference> | ||||
|         <PackageReference Include="External.Common.Logging" Version="3.3.1"><NoWarn>NU1701</NoWarn></PackageReference> | ||||
|         <PackageReference Include="External.log4net" Version="2.0.8"><NoWarn>NU1701</NoWarn></PackageReference> | ||||
|         <PackageReference Include="Tesseract" Version="5.2.0" /> | ||||
|     </ItemGroup> | ||||
|     <ItemGroup> | ||||
|         <None Include="appsettings.json"> | ||||
|  | ||||
| @ -1,3 +1,9 @@ | ||||
| # D: | ||||
| # cd D:\EAF-Mesa-Integration | ||||
| # config --url https://tfs.intra.infineon.com/tfs/FactoryIntegration --pool "EAF Mesa Integration" --agent mestsa003-meseafsvc --work _work --runAsService --auth negotiate --userName infineon\phares | ||||
| # D: | ||||
| # cd D:\EAF-Mesa-Integration | ||||
| # config --url https://tfs.intra.infineon.com/tfs/FactoryIntegration --pool "EAF Mesa Integration" --agent mestsa07ec-ecmeseaf --work _work --runAsService --auth negotiate --userName infineon\phares | ||||
| trigger: | ||||
|   branches: | ||||
|     include: | ||||
| @ -6,180 +12,273 @@ trigger: | ||||
|     include: | ||||
|       - "Adaptation/*" | ||||
|  | ||||
| pool: | ||||
|   name: eaf | ||||
|   demands: MET08RESIMAPCDE | ||||
| stages: | ||||
|   - stage: DevServer | ||||
|     displayName: DevServer | ||||
|  | ||||
| steps: | ||||
|   - script: | | ||||
|       set coreVersion=net7.0 | ||||
|       echo %coreVersion% | ||||
|       echo ##vso[task.setvariable variable=CoreVersion;]%coreVersion% | ||||
|       echo $(CoreVersion) | ||||
|     displayName: CoreVersion | ||||
|     pool: | ||||
|       name: EAF Mesa Integration | ||||
|       demands: MET08RESIMAPCDE-Development | ||||
|  | ||||
|   - script: | | ||||
|       set configuration=Release | ||||
|       echo %configuration% | ||||
|       echo ##vso[task.setvariable variable=Configuration;]%configuration% | ||||
|       echo $(Configuration) | ||||
|     displayName: Configuration | ||||
|     variables: | ||||
|       coreVersion: "net8.0" | ||||
|       nugetSource: "https://artifactory.intra.infineon.com/artifactory/api/nuget/ngt-fi-package-main-vir/" | ||||
|  | ||||
|   - script: | | ||||
|       set nugetSource=https://artifactory.intra.infineon.com/artifactory/api/nuget/ngt-fi-package-main-vir/index.json;D:/vsts-agent-win-x64-2.210.1-eaf/nuget | ||||
|       echo %nugetSource% | ||||
|       echo ##vso[task.setvariable variable=NugetSource;]%nugetSource% | ||||
|       echo $(NugetSource) | ||||
|     displayName: NugetSource | ||||
|     jobs: | ||||
|       - job: SetupEnvironment | ||||
|         steps: | ||||
|           - script: | | ||||
|               echo $(Build.BuildId) | ||||
|               echo $(Build.Reason) | ||||
|               echo $(Build.Repository.Id) | ||||
|               echo $(Build.Repository.Name) | ||||
|               echo $(Build.SourceVersion) | ||||
|               echo $(CoreVersion) | ||||
|               echo $(NugetSource) | ||||
|             displayName: "Echo Check" | ||||
|  | ||||
|   - script: | | ||||
|       set gitCommit=$(Build.SourceVersion) | ||||
|       set gitCommitSeven=%gitCommit:~0,7% | ||||
|       echo %gitCommitSeven% | ||||
|       echo ##vso[task.setvariable variable=GitCommitSeven;]%gitCommitSeven% | ||||
|       echo $(GitCommitSeven) | ||||
|     displayName: GitCommitSeven | ||||
|           - script: '"C:\program files\dotnet\dotnet.exe" nuget locals all --clear' | ||||
|             displayName: "Nuget Clear" | ||||
|             enabled: false | ||||
|  | ||||
|   - script: | | ||||
|       echo $(Build.BuildId) | ||||
|       echo $(Build.Reason) | ||||
|       echo $(Build.Repository.Id) | ||||
|       echo $(Build.Repository.Name) | ||||
|       echo $(Build.SourceVersion) | ||||
|       echo $(CoreVersion) | ||||
|       echo $(Configuration) | ||||
|       echo $(NugetSource) | ||||
|       echo $(GitCommitSeven) | ||||
|       REM echo $(pipelinePassword) | ||||
|     displayName: "Echo Check" | ||||
|           - script: | | ||||
|               "C:\program files\dotnet\dotnet.exe" user-secrets init | ||||
|               "C:\program files\dotnet\dotnet.exe" user-secrets set "BuildNumber" "$(Build.BuildId)" | ||||
|               "C:\program files\dotnet\dotnet.exe" user-secrets set "GitCommit" "$(Build.SourceVersion)" | ||||
|               "C:\program files\dotnet\dotnet.exe" user-secrets list | ||||
|             workingDirectory: Adaptation | ||||
|             displayName: "Safe storage of app secrets - Adaptation" | ||||
|  | ||||
|   - script: '"C:\program files\dotnet\dotnet.exe" nuget locals all --clear' | ||||
|     displayName: "Nuget Clear" | ||||
|     enabled: false | ||||
|       - job: BuildDebug | ||||
|         dependsOn: | ||||
|           - SetupEnvironment | ||||
|         steps: | ||||
|           - script: | | ||||
|               set configuration=Debug | ||||
|               echo %configuration% | ||||
|               echo ##vso[task.setvariable variable=Configuration;]%configuration% | ||||
|               echo $(Configuration) | ||||
|             displayName: Configuration | ||||
|  | ||||
|   - script: | | ||||
|       "C:\program files\dotnet\dotnet.exe" user-secrets init | ||||
|       "C:\program files\dotnet\dotnet.exe" user-secrets set "BuildNumber" "$(Build.BuildId)" | ||||
|       "C:\program files\dotnet\dotnet.exe" user-secrets set "GitCommitSeven" "$(GitCommitSeven)" | ||||
|       "C:\program files\dotnet\dotnet.exe" user-secrets list | ||||
|     workingDirectory: Adaptation | ||||
|     displayName: "Safe storage of app secrets - Adaptation" | ||||
|           - script: '"C:\program files\dotnet\dotnet.exe" build --configuration $(Configuration) --source $(NugetSource)' | ||||
|             workingDirectory: Adaptation | ||||
|             displayName: "Core Build - Adaptation" | ||||
|  | ||||
|   - task: CopyFiles@2 | ||||
|     displayName: "Copy Files to: - GhostPCL" | ||||
|     inputs: | ||||
|       Contents: '*' | ||||
|       SourceFolder: '\\mesfs.infineon.com\EC_EAFRepository\Staging\DeploymentStorage\GhostPCL\gpcl6win64' | ||||
|       TargetFolder: 'Adaptation\bin\$(Configuration)\net6.0\win-x64' | ||||
|       OverWrite: true | ||||
|       - job: BuildRelease | ||||
|         dependsOn: | ||||
|           - SetupEnvironment | ||||
|         steps: | ||||
|           - script: | | ||||
|               set configuration=Release | ||||
|               echo %configuration% | ||||
|               echo ##vso[task.setvariable variable=Configuration;]%configuration% | ||||
|               echo $(Configuration) | ||||
|             displayName: Configuration | ||||
|  | ||||
|   - task: CopyFiles@2 | ||||
|     displayName: "Copy Files to: - LincPDFC" | ||||
|     inputs: | ||||
|       Contents: '*' | ||||
|       SourceFolder: '\\mesfs.infineon.com\EC_EAFRepository\Staging\DeploymentStorage\LincPDFC\v2.6.6.21' | ||||
|       TargetFolder: 'Adaptation\bin\$(Configuration)\net6.0\win-x64' | ||||
|       OverWrite: true | ||||
|           - script: '"C:/Program Files (x86)/Microsoft Visual Studio/2022/BuildTools/MSBuild/Current/Bin/MSBuild.exe" /target:Restore /detailedsummary /consoleloggerparameters:PerformanceSummary;ErrorsOnly; /property:Configuration=$(Configuration);TargetFrameworkVersion=v4.8 /p:RestoreSources=$(NugetSource)' | ||||
|             displayName: "MSBuild Restore" | ||||
|  | ||||
|   - task: CopyFiles@2 | ||||
|     displayName: "Copy Files to: - PDF-Text-Stripper" | ||||
|     inputs: | ||||
|       Contents: '*' | ||||
|       SourceFolder: '\\mesfs.infineon.com\EC_EAFRepository\Staging\DeploymentStorage\PDF-Text-Stripper\v4.8.0.1' | ||||
|       TargetFolder: 'Adaptation\bin\$(Configuration)\net6.0\win-x64' | ||||
|       OverWrite: true | ||||
|           - script: '"C:/Program Files (x86)/Microsoft Visual Studio/2022/BuildTools/MSBuild/Current/Bin/MSBuild.exe" /target:Build /detailedsummary /consoleloggerparameters:PerformanceSummary;ErrorsOnly; /property:Configuration=$(Configuration);TargetFrameworkVersion=v4.8' | ||||
|             displayName: MSBuild | ||||
|  | ||||
|   - script: '"C:\program files\dotnet\dotnet.exe" build --configuration $(Configuration) --source $(NugetSource)' | ||||
|     workingDirectory: Adaptation | ||||
|     displayName: "Core Build - Adaptation" | ||||
|           - script: '"C:/Program Files (x86)/Microsoft Visual Studio/2022/BuildTools/MSBuild/Current/Bin/MSBuild.exe" /target:Build /detailedsummary /consoleloggerparameters:PerformanceSummary;ErrorsOnly; /property:Configuration=$(Configuration);TargetFrameworkVersion=v4.8' | ||||
|             displayName: MSBuild | ||||
|  | ||||
|   - powershell: Get-ChildItem .\ -include TestResults -Recurse | foreach ($_) { remove-item $_.fullname -Force -Recurse } | ||||
|     workingDirectory: "$(System.DefaultWorkingDirectory)/../../../$(Build.Repository.Name)" | ||||
|     displayName: "PowerShell Script" | ||||
|     continueOnError: true | ||||
|           - script: 'echo $(Build.Repository.Name)-$(Build.BuildId)-$(Build.SourceVersion)>bin\$(Configuration)\$(Build.Repository.Name).txt' | ||||
|             displayName: "Commit Id" | ||||
|  | ||||
|   - script: "dotnet test --configuration $(Configuration)" | ||||
|     workingDirectory: Adaptation | ||||
|     displayName: "Core Test" | ||||
|           - task: CopyFiles@2 | ||||
|             displayName: 'Copy Files to: D:\EAF' | ||||
|             inputs: | ||||
|               Contents: "*$(Build.Repository.Name)*" | ||||
|               SourceFolder: 'bin\$(Configuration)' | ||||
|               TargetFolder: 'D:\EAF\EAF Deployment Storage\Adaptation_$(Build.Repository.Name)' | ||||
|               OverWrite: true | ||||
|             enabled: true | ||||
|  | ||||
|   - script: 'move /y "$(System.DefaultWorkingDirectory)/../../../$(Build.Repository.Name)/05_TestResults/TestResults" $(System.DefaultWorkingDirectory)' | ||||
|     displayName: "Move Results" | ||||
|       - job: TestDebug | ||||
|         dependsOn: | ||||
|           - SetupEnvironment | ||||
|           - BuildDebug | ||||
|           - BuildRelease | ||||
|         steps: | ||||
|           - script: | | ||||
|               set configuration=Debug | ||||
|               echo %configuration% | ||||
|               echo ##vso[task.setvariable variable=Configuration;]%configuration% | ||||
|               echo $(Configuration) | ||||
|             displayName: Configuration | ||||
|  | ||||
|   - script: '"C:\program files\dotnet\dotnet.exe" tool restore' | ||||
|     workingDirectory: Adaptation | ||||
|     displayName: "Tool Restore" | ||||
|     enabled: false | ||||
|           - powershell: Get-ChildItem .\ -include TestResults -Recurse | foreach ($_) { remove-item $_.fullname -Force -Recurse } | ||||
|             workingDirectory: "$(System.DefaultWorkingDirectory)/../../../$(Build.Repository.Name)" | ||||
|             displayName: "PowerShell Script" | ||||
|             continueOnError: true | ||||
|  | ||||
|   - script: '"C:\program files\dotnet\dotnet.exe" ReportGenerator -reports:$(System.DefaultWorkingDirectory)/TestResults/**/coverage.cobertura.xml -targetDir:$(Build.ArtifactStagingDirectory)\Coverage -reportTypes:Html_Dark' | ||||
|     workingDirectory: Adaptation | ||||
|     displayName: "Report Generator" | ||||
|     enabled: false | ||||
|           - script: "dotnet test --configuration $(Configuration)" | ||||
|             workingDirectory: Adaptation | ||||
|             displayName: "Core Test" | ||||
|  | ||||
|   - task: PublishTestResults@2 | ||||
|     displayName: "Publish Test Results **/*.trx" | ||||
|     inputs: | ||||
|       testResultsFormat: VSTest | ||||
|       testResultsFiles: "**/*.trx" | ||||
|       testRunTitle: "$(GitCommitSeven)-$(Build.BuildId)-$(CoreVersion)-$(Configuration)-$(Build.Repository.Name)" | ||||
|       searchFolder: "$(System.DefaultWorkingDirectory)/TestResults" | ||||
|           - script: 'move /y "$(System.DefaultWorkingDirectory)/../../../$(Build.Repository.Name)/05_TestResults/TestResults" $(System.DefaultWorkingDirectory)' | ||||
|             displayName: "Move Results" | ||||
|  | ||||
|   - task: PublishTestResults@2 | ||||
|     displayName: "Publish Test Results */coverage.cobertura.xml" | ||||
|     inputs: | ||||
|       testResultsFormat: VSTest | ||||
|       testResultsFiles: "*/coverage.cobertura.xml" | ||||
|       testRunTitle: "$(GitCommitSeven)-$(Build.BuildId)-$(CoreVersion)-$(Configuration)-$(Build.Repository.Name)" | ||||
|       searchFolder: "$(System.DefaultWorkingDirectory)/TestResults" | ||||
|           - script: '"C:\program files\dotnet\dotnet.exe" tool restore' | ||||
|             workingDirectory: Adaptation | ||||
|             displayName: "Tool Restore" | ||||
|             enabled: false | ||||
|  | ||||
|   - task: mspremier.CreateWorkItem.CreateWorkItem-task.CreateWorkItem@1 | ||||
|     displayName: "Create work item" | ||||
|     inputs: | ||||
|       teamProject: "Mesa_FI" | ||||
|       workItemType: Bug | ||||
|       title: $(GitCommitSeven)-$(Build.BuildId)-$(Build.Repository.Name)-$(Configuration) | ||||
|       assignedTo: "$(Build.RequestedForId)" | ||||
|     enabled: false | ||||
|           - script: '"C:\program files\dotnet\dotnet.exe" ReportGenerator -reports:$(System.DefaultWorkingDirectory)/TestResults/**/coverage.cobertura.xml -targetDir:$(Build.ArtifactStagingDirectory)\Coverage -reportTypes:Html_Dark' | ||||
|             workingDirectory: Adaptation | ||||
|             displayName: "Report Generator" | ||||
|             enabled: false | ||||
|  | ||||
|   - script: '"C:\program files\dotnet\dotnet.exe" publish --configuration $(Configuration) --runtime win-x64 --self-contained -o $(Build.ArtifactStagingDirectory)\Adaptation --source $(NugetSource)' | ||||
|     workingDirectory: Adaptation | ||||
|     displayName: "Core Publish" | ||||
|     enabled: false | ||||
|           - task: PublishTestResults@2 | ||||
|             displayName: "Publish Test Results **/*.trx" | ||||
|             inputs: | ||||
|               testResultsFormat: VSTest | ||||
|               testResultsFiles: "**/*.trx" | ||||
|               testRunTitle: "$(Build.BuildId)-$(Build.SourceVersion)-$(CoreVersion)-$(Configuration)-$(Build.Repository.Name)" | ||||
|               searchFolder: "$(System.DefaultWorkingDirectory)/TestResults" | ||||
|  | ||||
|   - script: '"C:/Program Files (x86)/Microsoft Visual Studio/2022/BuildTools/MSBuild/Current/Bin/MSBuild.exe" /target:Restore /detailedsummary /consoleloggerparameters:PerformanceSummary;ErrorsOnly; /property:Configuration=$(Configuration);TargetFrameworkVersion=v4.8 /p:RestoreSources="$(NugetSource)"' | ||||
|     displayName: "MSBuild Restore" | ||||
|           - task: PublishTestResults@2 | ||||
|             displayName: "Publish Test Results */coverage.cobertura.xml" | ||||
|             inputs: | ||||
|               testResultsFormat: VSTest | ||||
|               testResultsFiles: "*/coverage.cobertura.xml" | ||||
|               testRunTitle: "$(Build.BuildId)-$(Build.SourceVersion)-$(CoreVersion)-$(Configuration)-$(Build.Repository.Name)" | ||||
|               searchFolder: "$(System.DefaultWorkingDirectory)/TestResults" | ||||
|  | ||||
|   - script: '"C:/Program Files (x86)/Microsoft Visual Studio/2022/BuildTools/MSBuild/Current/Bin/MSBuild.exe" /target:Build /detailedsummary /consoleloggerparameters:PerformanceSummary;ErrorsOnly; /property:Configuration=$(Configuration);TargetFrameworkVersion=v4.8' | ||||
|     displayName: MSBuild | ||||
|           - script: | | ||||
|               "C:\program files\dotnet\dotnet.exe" clean --configuration $(Configuration) | ||||
|             workingDirectory: Adaptation | ||||
|             displayName: "Core Clean - Adaptation" | ||||
|  | ||||
|   - script: 'echo $(Build.SourceVersion)-$(Build.BuildId)-$(Build.Repository.Name)>bin\$(Configuration)\$(Build.Repository.Name).txt' | ||||
|     displayName: "Commit Id" | ||||
|           - script: 'echo $(Build.BuildId)-$(Build.SourceVersion)-bin_x_x_\$(Configuration)\$(CoreVersion)\win-x64\$(Build.Repository.Name).txt' | ||||
|             displayName: "Force Fail" | ||||
|             enabled: false | ||||
|  | ||||
|   - task: CopyFiles@2 | ||||
|     displayName: 'Copy Files to: D:\Framework4.8' | ||||
|     inputs: | ||||
|       Contents: "*$(Build.Repository.Name)*" | ||||
|       SourceFolder: 'bin\$(Configuration)' | ||||
|       TargetFolder: 'D:\Framework4.8\$(GitCommitSeven)-$(Build.BuildId)-$(Build.Repository.Name)-$(Configuration)' | ||||
|       OverWrite: true | ||||
|   - stage: ProductionServer | ||||
|     displayName: ProductionServer | ||||
|  | ||||
|   - task: CopyFiles@2 | ||||
|     displayName: 'Copy Files to: Local D EAF Deployment Storage' | ||||
|     inputs: | ||||
|       Contents: "*$(Build.Repository.Name)*" | ||||
|       SourceFolder: 'bin\$(Configuration)' | ||||
|       TargetFolder: 'D:\EAF\EAF Deployment Storage\Adaptation_$(Build.Repository.Name)' | ||||
|       OverWrite: true | ||||
|     pool: | ||||
|       name: EAF Mesa Integration | ||||
|       demands: MET08RESIMAPCDE | ||||
|  | ||||
|   - script: | | ||||
|       "C:\program files\dotnet\dotnet.exe" clean --configuration $(Configuration) | ||||
|     workingDirectory: Adaptation | ||||
|     displayName: "Core Clean - Tests" | ||||
|     variables: | ||||
|       coreVersion: "net8.0" | ||||
|       nugetSource: "https://artifactory.intra.infineon.com/artifactory/api/nuget/ngt-fi-package-main-vir/" | ||||
|  | ||||
|   - script: | | ||||
|       "C:\program files\dotnet\dotnet.exe" clean --configuration $(Configuration) | ||||
|     workingDirectory: Adaptation | ||||
|     displayName: "Core Clean - Adaptation" | ||||
|     jobs: | ||||
|       - job: SetupEnvironment | ||||
|         steps: | ||||
|           - script: | | ||||
|               echo $(Build.BuildId) | ||||
|               echo $(Build.Reason) | ||||
|               echo $(Build.Repository.Id) | ||||
|               echo $(Build.Repository.Name) | ||||
|               echo $(Build.SourceVersion) | ||||
|               echo $(CoreVersion) | ||||
|               echo $(NugetSource) | ||||
|             displayName: "Echo Check" | ||||
|  | ||||
|   - script: 'echo $(Build.SourceVersion)-$(Build.BuildId)>bin_x_x_\$(Configuration)\$(CoreVersion)\win-x64\$(Build.Repository.Name).txt' | ||||
|     displayName: "Force Fail" | ||||
|     enabled: false | ||||
|           - script: '"C:\program files\dotnet\dotnet.exe" nuget locals all --clear' | ||||
|             displayName: "Nuget Clear" | ||||
|             enabled: false | ||||
|  | ||||
|           - script: | | ||||
|               "C:\program files\dotnet\dotnet.exe" user-secrets init | ||||
|               "C:\program files\dotnet\dotnet.exe" user-secrets set "BuildNumber" "$(Build.BuildId)" | ||||
|               "C:\program files\dotnet\dotnet.exe" user-secrets set "GitCommit" "$(Build.SourceVersion)" | ||||
|               "C:\program files\dotnet\dotnet.exe" user-secrets list | ||||
|             workingDirectory: Adaptation | ||||
|             displayName: "Safe storage of app secrets - Adaptation" | ||||
|  | ||||
|       - job: BuildRelease | ||||
|         dependsOn: | ||||
|           - SetupEnvironment | ||||
|         steps: | ||||
|           - script: | | ||||
|               set configuration=Release | ||||
|               echo %configuration% | ||||
|               echo ##vso[task.setvariable variable=Configuration;]%configuration% | ||||
|               echo $(Configuration) | ||||
|             displayName: Configuration | ||||
|  | ||||
|           - script: '"C:/Program Files (x86)/Microsoft Visual Studio/2022/BuildTools/MSBuild/Current/Bin/MSBuild.exe" /target:Restore /detailedsummary /consoleloggerparameters:PerformanceSummary;ErrorsOnly; /property:Configuration=$(Configuration);TargetFrameworkVersion=v4.8 /p:RestoreSources=$(NugetSource)' | ||||
|             displayName: "MSBuild Restore" | ||||
|  | ||||
|           - script: '"C:/Program Files (x86)/Microsoft Visual Studio/2022/BuildTools/MSBuild/Current/Bin/MSBuild.exe" /target:Build /detailedsummary /consoleloggerparameters:PerformanceSummary;ErrorsOnly; /property:Configuration=$(Configuration);TargetFrameworkVersion=v4.8' | ||||
|             displayName: MSBuild | ||||
|  | ||||
|           - script: 'echo $(Build.Repository.Name)-$(Build.BuildId)-$(Build.SourceVersion)>bin\$(Configuration)\$(Build.Repository.Name).txt' | ||||
|             displayName: "Commit Id" | ||||
|  | ||||
|           - task: CopyFiles@2 | ||||
|             displayName: 'Copy Files to: D:\EAF' | ||||
|             inputs: | ||||
|               Contents: "*$(Build.Repository.Name)*" | ||||
|               SourceFolder: 'bin\$(Configuration)' | ||||
|               TargetFolder: 'D:\EAF\EAF Deployment Storage\Adaptation_$(Build.Repository.Name)' | ||||
|               OverWrite: true | ||||
|  | ||||
|           - script: '"C:\program files\dotnet\dotnet.exe" build --configuration $(Configuration) --source $(NugetSource)' | ||||
|             workingDirectory: Adaptation | ||||
|             displayName: "Core Build - Adaptation" | ||||
|  | ||||
|       - job: TestRelease | ||||
|         dependsOn: | ||||
|           - SetupEnvironment | ||||
|           - BuildRelease | ||||
|         steps: | ||||
|           - script: | | ||||
|               set configuration=Release | ||||
|               echo %configuration% | ||||
|               echo ##vso[task.setvariable variable=Configuration;]%configuration% | ||||
|               echo $(Configuration) | ||||
|             displayName: Configuration | ||||
|  | ||||
|           - powershell: Get-ChildItem .\ -include TestResults -Recurse | foreach ($_) { remove-item $_.fullname -Force -Recurse } | ||||
|             workingDirectory: "$(System.DefaultWorkingDirectory)/../../../$(Build.Repository.Name)" | ||||
|             displayName: "PowerShell Script" | ||||
|             continueOnError: true | ||||
|  | ||||
|           - script: "dotnet test --configuration $(Configuration)" | ||||
|             workingDirectory: Adaptation | ||||
|             displayName: "Core Test" | ||||
|  | ||||
|           - script: 'move /y "$(System.DefaultWorkingDirectory)/../../../$(Build.Repository.Name)/05_TestResults/TestResults" $(System.DefaultWorkingDirectory)' | ||||
|             displayName: "Move Results" | ||||
|  | ||||
|           - script: '"C:\program files\dotnet\dotnet.exe" tool restore' | ||||
|             workingDirectory: Adaptation | ||||
|             displayName: "Tool Restore" | ||||
|             enabled: false | ||||
|  | ||||
|           - script: '"C:\program files\dotnet\dotnet.exe" ReportGenerator -reports:$(System.DefaultWorkingDirectory)/TestResults/**/coverage.cobertura.xml -targetDir:$(Build.ArtifactStagingDirectory)\Coverage -reportTypes:Html_Dark' | ||||
|             workingDirectory: Adaptation | ||||
|             displayName: "Report Generator" | ||||
|             enabled: false | ||||
|  | ||||
|           - task: PublishTestResults@2 | ||||
|             displayName: "Publish Test Results **/*.trx" | ||||
|             inputs: | ||||
|               testResultsFormat: VSTest | ||||
|               testResultsFiles: "**/*.trx" | ||||
|               testRunTitle: "$(Build.BuildId)-$(Build.SourceVersion)-$(CoreVersion)-$(Configuration)-$(Build.Repository.Name)" | ||||
|               searchFolder: "$(System.DefaultWorkingDirectory)/TestResults" | ||||
|  | ||||
|           - task: PublishTestResults@2 | ||||
|             displayName: "Publish Test Results */coverage.cobertura.xml" | ||||
|             inputs: | ||||
|               testResultsFormat: VSTest | ||||
|               testResultsFiles: "*/coverage.cobertura.xml" | ||||
|               testRunTitle: "$(Build.BuildId)-$(Build.SourceVersion)-$(CoreVersion)-$(Configuration)-$(Build.Repository.Name)" | ||||
|               searchFolder: "$(System.DefaultWorkingDirectory)/TestResults" | ||||
|  | ||||
|           - script: | | ||||
|               "C:\program files\dotnet\dotnet.exe" clean --configuration $(Configuration) | ||||
|             workingDirectory: Adaptation | ||||
|             displayName: "Core Clean - Adaptation" | ||||
|  | ||||
|           - script: 'echo $(Build.BuildId)-$(Build.SourceVersion)-bin_x_x_\$(Configuration)\$(CoreVersion)\win-x64\$(Build.Repository.Name).txt' | ||||
|             displayName: "Force Fail" | ||||
|             enabled: true | ||||
|  | ||||
| @ -3,6 +3,7 @@ using System; | ||||
| using System.Collections.Generic; | ||||
| using System.Linq; | ||||
| using System.Text.Json; | ||||
| using System.Text.Json.Serialization; | ||||
|  | ||||
| namespace Adaptation.Shared.Duplicator; | ||||
|  | ||||
| @ -178,4 +179,16 @@ public class Description : IDescription, Properties.IDescription | ||||
|  | ||||
|     internal static string GetDateFormat() => "MM/dd/yyyy hh:mm:ss tt"; | ||||
|  | ||||
| } | ||||
|  | ||||
| [JsonSourceGenerationOptions(WriteIndented = true, NumberHandling = JsonNumberHandling.AllowReadingFromString | JsonNumberHandling.WriteAsString)] | ||||
| [JsonSerializable(typeof(Description))] | ||||
| internal partial class SharedDescriptionSourceGenerationContext : JsonSerializerContext | ||||
| { | ||||
| } | ||||
|  | ||||
| [JsonSourceGenerationOptions(WriteIndented = true, NumberHandling = JsonNumberHandling.AllowReadingFromString | JsonNumberHandling.WriteAsString)] | ||||
| [JsonSerializable(typeof(Description[]))] | ||||
| internal partial class SharedDescriptionArraySourceGenerationContext : JsonSerializerContext | ||||
| { | ||||
| } | ||||
										
											
												File diff suppressed because it is too large
												Load Diff
											
										
									
								
							| @ -35,6 +35,9 @@ public class Logistics : ILogistics | ||||
|     public long Sequence => _Sequence; | ||||
|     public double TotalSecondsSinceLastWriteTimeFromSequence => _TotalSecondsSinceLastWriteTimeFromSequence; | ||||
|  | ||||
|     private static string DefaultMesEntity(DateTime dateTime) => | ||||
|         string.Concat(dateTime.Ticks, "_MES_ENTITY"); | ||||
|  | ||||
|     public Logistics(IFileRead fileRead) | ||||
|     { | ||||
|         DateTime dateTime = DateTime.Now; | ||||
| @ -84,13 +87,13 @@ public class Logistics : ILogistics | ||||
|         _Logistics2 = new List<Logistics2>(); | ||||
|     } | ||||
|  | ||||
|     public Logistics(string reportFullPath, string logistics) | ||||
|     internal Logistics(string reportFullPath, ProcessDataStandardFormat processDataStandardFormat) | ||||
|     { | ||||
|         string key; | ||||
|         DateTime dateTime; | ||||
|         string[] segments; | ||||
|         _FileInfo = new(reportFullPath); | ||||
|         _Logistics1 = logistics.Split(new string[] { Environment.NewLine }, StringSplitOptions.RemoveEmptyEntries).ToList(); | ||||
|         _Logistics1 = processDataStandardFormat.Logistics.ToList(); | ||||
|         if (Logistics1.Count == 0 || !Logistics1[0].StartsWith("LOGISTICS_1")) | ||||
|         { | ||||
|             _NullData = null; | ||||
| @ -190,8 +193,6 @@ public class Logistics : ILogistics | ||||
|         } | ||||
|     } | ||||
|  | ||||
|     private static string DefaultMesEntity(DateTime dateTime) => string.Concat(dateTime.Ticks, "_MES_ENTITY"); | ||||
|  | ||||
|     internal void Update(string mid, string processJobID) | ||||
|     { | ||||
|         _MID = mid; | ||||
|  | ||||
| @ -6,23 +6,25 @@ public partial class WS | ||||
|     public class Attachment | ||||
|     { | ||||
|  | ||||
|         public string SubGroupId { get; set; } | ||||
|         public long HeaderId { get; set; } | ||||
|         public string HeaderIdDirectory { get; set; } | ||||
|         public string UniqueId { get; set; } | ||||
|         public string DestinationFileName { get; set; } | ||||
|         public string SourceFileName { get; set; } | ||||
|         public string AttachmentId { get; set; } | ||||
| #nullable enable | ||||
|  | ||||
|         public Attachment(string subGroupId, long headerId, string headerIdDirectory, string uniqueId, string destinationFileName, string sourceFileName) | ||||
|         public long HeaderId { get; set; } | ||||
|         public string UniqueId { get; set; } | ||||
|         public string SubGroupId { get; set; } | ||||
|         public string AttachmentId { get; set; } | ||||
|         public string SourceFileName { get; set; } | ||||
|         public string HeaderIdDirectory { get; set; } | ||||
|         public string DestinationFileName { get; set; } | ||||
|  | ||||
|         public Attachment(Results? results, string headerIdDirectory, string uniqueId, string destinationFileName, string sourceFileName) | ||||
|         { | ||||
|             SubGroupId = subGroupId; | ||||
|             HeaderId = headerId; | ||||
|             HeaderIdDirectory = headerIdDirectory; | ||||
|             UniqueId = uniqueId; | ||||
|             DestinationFileName = destinationFileName; | ||||
|             SourceFileName = sourceFileName; | ||||
|             HeaderIdDirectory = headerIdDirectory; | ||||
|             DestinationFileName = destinationFileName; | ||||
|             AttachmentId = System.Guid.NewGuid().ToString(); | ||||
|             HeaderId = results?.HeaderId is null ? -1 : results.HeaderId.Value; | ||||
|             SubGroupId = results?.SubgroupId is null ? string.Empty : results.SubgroupId.Value.ToString(); | ||||
|         } | ||||
|  | ||||
|     } | ||||
|  | ||||
| @ -1,27 +1,75 @@ | ||||
| using System.Collections.Generic; | ||||
| using System; | ||||
| using System.Collections.Generic; | ||||
| using System.Text; | ||||
| using System.Text.Json; | ||||
| using System.Text.Json.Serialization; | ||||
|  | ||||
| namespace Adaptation.Shared.Metrology; | ||||
|  | ||||
| public partial class WS | ||||
| { | ||||
|     // this class represents the response from the Inbound API endpoint | ||||
|  | ||||
|     public class Results | ||||
|     { | ||||
|         // true or false if data was written to the database | ||||
|         public bool Success { get; set; } | ||||
|  | ||||
|         // if true, contains ID of the Header record in the database | ||||
|         public long HeaderID { get; set; } | ||||
| #nullable enable | ||||
|  | ||||
|         // if false, this collection will contain a list of errors | ||||
|         public List<string> Errors { get; set; } | ||||
|         [JsonConstructor] | ||||
|         public Results(List<string>? errors, | ||||
|                        long? headerId, | ||||
|                        long? subgroupId, | ||||
|                        bool? success, | ||||
|                        List<string>? warnings) | ||||
|         { | ||||
|             Errors = errors; | ||||
|             Success = success; | ||||
|             HeaderId = headerId; | ||||
|             Warnings = warnings; | ||||
|             SubgroupId = subgroupId; | ||||
|         } | ||||
|  | ||||
|         // this collection will contain a list of warnings, they will not prevent data from being saved | ||||
|         public List<string> Warnings { get; set; } | ||||
|         [JsonPropertyName("errors")] public List<string>? Errors { get; set; } | ||||
|         [JsonPropertyName("headerID")] public long? HeaderId { get; set; } | ||||
|         [JsonPropertyName("subgroupId")] public long? SubgroupId { get; set; } | ||||
|         [JsonPropertyName("success")] public bool? Success { get; set; } | ||||
|         [JsonPropertyName("warnings")] public List<string>? Warnings { get; set; } | ||||
|  | ||||
|         public override string ToString() | ||||
|         { | ||||
|             string result = JsonSerializer.Serialize(this, ResultsSourceGenerationContext.Default.Results); | ||||
|             return result; | ||||
|         } | ||||
|  | ||||
|         internal static Results Get(Results results, long? subgroupId) => | ||||
|             new(results.Errors, results.HeaderId, subgroupId, results.Success, results.Warnings); | ||||
|  | ||||
|         internal static Results Get(string resultsJson, Exception e) | ||||
|         { | ||||
|             Results results; | ||||
|             Exception? exception = e; | ||||
|             List<string> errors = new(); | ||||
|             StringBuilder stringBuilder = new(); | ||||
|             while (exception is not null) | ||||
|             { | ||||
|                 _ = stringBuilder.AppendLine(exception.Message); | ||||
|                 exception = exception.InnerException; | ||||
|             } | ||||
|             errors.Add(resultsJson); | ||||
|             errors.Add(stringBuilder.ToString()); | ||||
|             results = new(errors: errors, | ||||
|                           headerId: null, | ||||
|                           subgroupId: null, | ||||
|                           success: false, | ||||
|                           warnings: new()); | ||||
|             return results; | ||||
|         } | ||||
|  | ||||
|         // this is just a helper function to make displaying the results easier | ||||
|         public override string ToString() => JsonSerializer.Serialize(this, GetType()); | ||||
|     } | ||||
|  | ||||
| } | ||||
|  | ||||
| [JsonSourceGenerationOptions(WriteIndented = true)] | ||||
| [JsonSerializable(typeof(WS.Results))] | ||||
| internal partial class ResultsSourceGenerationContext : JsonSerializerContext | ||||
| { | ||||
| } | ||||
| @ -10,9 +10,11 @@ namespace Adaptation.Shared.Metrology; | ||||
| public partial class WS | ||||
| { | ||||
|  | ||||
| #nullable enable | ||||
|  | ||||
|     public static (string, Results) SendData(string url, long sequence, string directory, object payload, int timeoutSeconds = 120) | ||||
|     { | ||||
|         Results results = new(); | ||||
|         Results? wsResults = null; | ||||
|         string resultsJson = string.Empty; | ||||
|         try | ||||
|         { | ||||
| @ -30,29 +32,55 @@ public partial class WS | ||||
|                 }; | ||||
|                 HttpResponseMessage httpResponseMessage = httpClient.SendAsync(httpRequestMessage, HttpCompletionOption.ResponseContentRead).Result; | ||||
|                 resultsJson = httpResponseMessage.Content.ReadAsStringAsync().Result; | ||||
|                 results = JsonSerializer.Deserialize<Results>(resultsJson, new JsonSerializerOptions { PropertyNameCaseInsensitive = true }); | ||||
|                 string checkDirectory = Path.Combine(directory, $"-{results.HeaderID}"); | ||||
|                 wsResults = JsonSerializer.Deserialize(resultsJson, ResultsSourceGenerationContext.Default.Results); | ||||
|                 if (wsResults is null) | ||||
|                     throw new NullReferenceException(nameof(wsResults)); | ||||
|                 string checkDirectory = Path.Combine(directory, $"-{wsResults.HeaderId}"); | ||||
|                 if (!Directory.Exists(checkDirectory)) | ||||
|                     _ = Directory.CreateDirectory(checkDirectory); | ||||
|                 File.WriteAllText(Path.Combine(checkDirectory, $"{sequence}.json"), json); | ||||
|             } | ||||
|             if (!results.Success) | ||||
|                 results.Errors.Add(results.ToString()); | ||||
|             if (wsResults.Success is null || !wsResults.Success.Value) | ||||
|                 wsResults.Errors?.Add(wsResults.ToString()); | ||||
|         } | ||||
|         catch (Exception e) | ||||
|         { wsResults ??= Results.Get(resultsJson, e); } | ||||
|         return new(resultsJson, wsResults); | ||||
|     } | ||||
|  | ||||
|     public static (string, Results) SendData(string url, long sequence, string directory, string json, int timeoutSeconds = 120) | ||||
|     { | ||||
|         Results? wsResults = null; | ||||
|         string resultsJson = string.Empty; | ||||
|         try | ||||
|         { | ||||
|             Exception exception = e; | ||||
|             StringBuilder stringBuilder = new(); | ||||
|             while (exception is not null) | ||||
|             if (string.IsNullOrEmpty(url) || !url.Contains(":") || !url.Contains(".")) | ||||
|                 throw new Exception("Invalid URL"); | ||||
|             using (HttpClient httpClient = new()) | ||||
|             { | ||||
|                 _ = stringBuilder.AppendLine(exception.Message); | ||||
|                 exception = exception.InnerException; | ||||
|                 httpClient.Timeout = new TimeSpan(0, 0, 0, timeoutSeconds, 0); | ||||
|                 HttpRequestMessage httpRequestMessage = new() | ||||
|                 { | ||||
|                     RequestUri = new Uri(url), | ||||
|                     Method = HttpMethod.Post, | ||||
|                     Content = new StringContent(json, Encoding.UTF8, "application/json") | ||||
|                 }; | ||||
|                 HttpResponseMessage httpResponseMessage = httpClient.SendAsync(httpRequestMessage, HttpCompletionOption.ResponseContentRead).Result; | ||||
|                 resultsJson = httpResponseMessage.Content.ReadAsStringAsync().Result; | ||||
|                 wsResults = JsonSerializer.Deserialize(resultsJson, ResultsSourceGenerationContext.Default.Results); | ||||
|                 if (wsResults is null) | ||||
|                     throw new NullReferenceException(nameof(wsResults)); | ||||
|                 string checkDirectory = Path.Combine(directory, $"-{wsResults.HeaderId}"); | ||||
|                 if (!Directory.Exists(checkDirectory)) | ||||
|                     _ = Directory.CreateDirectory(checkDirectory); | ||||
|                 File.WriteAllText(Path.Combine(checkDirectory, $"{sequence}.json"), json); | ||||
|             } | ||||
|             results.Errors ??= new List<string>(); | ||||
|             results.Errors.Add(resultsJson); | ||||
|             results.Errors.Add(stringBuilder.ToString()); | ||||
|             if (wsResults.Success is null || !wsResults.Success.Value) | ||||
|                 wsResults.Errors?.Add(wsResults.ToString()); | ||||
|         } | ||||
|         return new(resultsJson, results); | ||||
|         catch (Exception e) | ||||
|         { wsResults ??= Results.Get(resultsJson, e); } | ||||
|         return new(resultsJson, wsResults); | ||||
|     } | ||||
|  | ||||
|     public static void AttachFile(string url, Attachment attachment, int timeoutSeconds = 60) | ||||
| @ -69,16 +97,20 @@ public partial class WS | ||||
|         } | ||||
|     } | ||||
|  | ||||
|     public static void AttachFiles(string url, List<Attachment> headerAttachments = null, List<Attachment> dataAttachments = null) | ||||
|     public static void AttachFiles(string url, List<Attachment>? headerAttachments = null, List<Attachment>? dataAttachments = null) | ||||
|     { | ||||
|         string directory; | ||||
|         try | ||||
|         { | ||||
|             string? directoryName; | ||||
|             if (headerAttachments is not null) | ||||
|             { | ||||
|                 foreach (Attachment attachment in headerAttachments) | ||||
|                 { | ||||
|                     directory = Path.Combine(Path.GetDirectoryName(attachment.HeaderIdDirectory), attachment.AttachmentId) ?? throw new Exception(); | ||||
|                     directoryName = Path.GetDirectoryName(attachment.HeaderIdDirectory); | ||||
|                     if (string.IsNullOrEmpty(directoryName)) | ||||
|                         continue; | ||||
|                     directory = Path.Combine(directoryName, attachment.AttachmentId) ?? throw new Exception(); | ||||
|                     if (!Directory.Exists(directory)) | ||||
|                         _ = Directory.CreateDirectory(directory); | ||||
|                     File.Copy(attachment.SourceFileName, Path.Combine(directory, attachment.DestinationFileName), overwrite: true); | ||||
| @ -88,7 +120,10 @@ public partial class WS | ||||
|             { | ||||
|                 foreach (Attachment attachment in dataAttachments) | ||||
|                 { | ||||
|                     directory = Path.Combine(Path.GetDirectoryName(attachment.HeaderIdDirectory.Replace("Header", "Data")), attachment.AttachmentId) ?? throw new Exception(); | ||||
|                     directoryName = Path.GetDirectoryName(attachment.HeaderIdDirectory.Replace("Header", "Data")); | ||||
|                     if (string.IsNullOrEmpty(directoryName)) | ||||
|                         continue; | ||||
|                     directory = Path.Combine(directoryName, attachment.AttachmentId) ?? throw new Exception(); | ||||
|                     if (!Directory.Exists(directory)) | ||||
|                         _ = Directory.CreateDirectory(directory); | ||||
|                     File.Copy(attachment.SourceFileName, Path.Combine(directory, attachment.DestinationFileName), overwrite: true); | ||||
| @ -108,7 +143,7 @@ public partial class WS | ||||
|         } | ||||
|         catch (Exception e) | ||||
|         { | ||||
|             Exception exception = e; | ||||
|             Exception? exception = e; | ||||
|             StringBuilder stringBuilder = new(); | ||||
|             while (exception is not null) | ||||
|             { | ||||
|  | ||||
										
											
												File diff suppressed because it is too large
												Load Diff
											
										
									
								
							
							
								
								
									
										34
									
								
								Adaptation/Shared/ProcessDataStandardFormatMapping.cs
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										34
									
								
								Adaptation/Shared/ProcessDataStandardFormatMapping.cs
									
									
									
									
									
										Normal file
									
								
							| @ -0,0 +1,34 @@ | ||||
| using System.Collections.ObjectModel; | ||||
| using System.Linq; | ||||
|  | ||||
| namespace Adaptation.Shared; | ||||
|  | ||||
| public class ProcessDataStandardFormatMapping | ||||
| { | ||||
|  | ||||
|     public ReadOnlyCollection<int> ColumnIndices { get; private set; } | ||||
|     public ReadOnlyCollection<string> NewColumnNames { get; private set; } | ||||
|     public ReadOnlyCollection<string> OldColumnNames { get; private set; } | ||||
|  | ||||
|     public ProcessDataStandardFormatMapping(ReadOnlyCollection<int> columnIndices, | ||||
|                                             ReadOnlyCollection<string> newColumnNames, | ||||
|                                             ReadOnlyCollection<string> oldColumnNames) | ||||
|     { | ||||
|         ColumnIndices = columnIndices; | ||||
|         NewColumnNames = newColumnNames; | ||||
|         OldColumnNames = oldColumnNames; | ||||
|     } | ||||
|  | ||||
|     internal static ProcessDataStandardFormatMapping Get(string processDataStandardFormatMappingOldColumnNames, string processDataStandardFormatMappingNewColumnNames, string processDataStandardFormatMappingColumnIndices) | ||||
|     { | ||||
|         ProcessDataStandardFormatMapping result; | ||||
|         ReadOnlyCollection<string> newColumnNames = new(processDataStandardFormatMappingNewColumnNames.Split(',')); | ||||
|         ReadOnlyCollection<string> oldColumnNames = new(processDataStandardFormatMappingOldColumnNames.Split(',')); | ||||
|         ReadOnlyCollection<int> columnIndices = new(processDataStandardFormatMappingColumnIndices.Split(',').Select(int.Parse).ToArray()); | ||||
|         result = new(columnIndices: columnIndices, | ||||
|                      newColumnNames: newColumnNames, | ||||
|                      oldColumnNames: oldColumnNames); | ||||
|         return result; | ||||
|     } | ||||
|  | ||||
| } | ||||
| @ -0,0 +1,65 @@ | ||||
| #if v2_57_0 | ||||
| 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_57_0; | ||||
|  | ||||
| [TestClass] | ||||
| public class CDE4 : EAFLoggingUnitTesting | ||||
| { | ||||
|  | ||||
| #pragma warning disable CA2254 | ||||
| #pragma warning disable IDE0060 | ||||
|  | ||||
|     internal static string DummyRoot { get; private set; } | ||||
|     internal static CDE4 EAFLoggingUnitTesting { get; private set; } | ||||
|  | ||||
|     static CDE4() => DummyRoot = @"\\mesfs.infineon.com\EC_Characterization_Si\Dummy"; | ||||
|  | ||||
|     public CDE4() : base(DummyRoot, testContext: null, declaringType: null, skipEquipmentDictionary: false) | ||||
|     { | ||||
|         if (EAFLoggingUnitTesting is null) | ||||
|             throw new Exception(); | ||||
|     } | ||||
|  | ||||
|     public CDE4(TestContext testContext) : base(DummyRoot, testContext, new StackFrame().GetMethod().DeclaringType, skipEquipmentDictionary: false) | ||||
|     { | ||||
|     } | ||||
|  | ||||
|     [ClassInitialize] | ||||
|     public static void ClassInitialize(TestContext testContext) | ||||
|     { | ||||
|         EAFLoggingUnitTesting ??= new CDE4(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_57_0__CDE4__RsM() | ||||
|     { | ||||
|         string check = "*.RsM"; | ||||
|         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,65 @@ | ||||
| #if v2_57_0 | ||||
| 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_57_0; | ||||
|  | ||||
| [TestClass] | ||||
| public class CDE5_EQPT : EAFLoggingUnitTesting | ||||
| { | ||||
|  | ||||
| #pragma warning disable CA2254 | ||||
| #pragma warning disable IDE0060 | ||||
|  | ||||
|     internal static string DummyRoot { get; private set; } | ||||
|     internal static CDE5_EQPT EAFLoggingUnitTesting { get; private set; } | ||||
|  | ||||
|     static CDE5_EQPT() => DummyRoot = @"\\mesfs.infineon.com\EC_Characterization_Si\Dummy"; | ||||
|  | ||||
|     public CDE5_EQPT() : base(DummyRoot, testContext: null, declaringType: null, skipEquipmentDictionary: false) | ||||
|     { | ||||
|         if (EAFLoggingUnitTesting is null) | ||||
|             throw new Exception(); | ||||
|     } | ||||
|  | ||||
|     public CDE5_EQPT(TestContext testContext) : base(DummyRoot, testContext, new StackFrame().GetMethod().DeclaringType, skipEquipmentDictionary: false) | ||||
|     { | ||||
|     } | ||||
|  | ||||
|     [ClassInitialize] | ||||
|     public static void ClassInitialize(TestContext testContext) | ||||
|     { | ||||
|         EAFLoggingUnitTesting ??= new CDE5_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(); | ||||
|     } | ||||
|  | ||||
| #if DEBUG | ||||
|     [Ignore] | ||||
| #endif | ||||
|     [TestMethod] | ||||
|     public void Production__v2_57_0__CDE5_EQPT__DownloadRsMFile() | ||||
|     { | ||||
|         string check = "CDE_Logs|WaferMeasurementData.log|.RsM"; | ||||
|         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,65 @@ | ||||
| #if v2_57_0 | ||||
| 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_57_0; | ||||
|  | ||||
| [TestClass] | ||||
| public class CDE5 : EAFLoggingUnitTesting | ||||
| { | ||||
|  | ||||
| #pragma warning disable CA2254 | ||||
| #pragma warning disable IDE0060 | ||||
|  | ||||
|     internal static string DummyRoot { get; private set; } | ||||
|     internal static CDE5 EAFLoggingUnitTesting { get; private set; } | ||||
|  | ||||
|     static CDE5() => DummyRoot = @"\\mesfs.infineon.com\EC_Characterization_Si\Dummy"; | ||||
|  | ||||
|     public CDE5() : base(DummyRoot, testContext: null, declaringType: null, skipEquipmentDictionary: false) | ||||
|     { | ||||
|         if (EAFLoggingUnitTesting is null) | ||||
|             throw new Exception(); | ||||
|     } | ||||
|  | ||||
|     public CDE5(TestContext testContext) : base(DummyRoot, testContext, new StackFrame().GetMethod().DeclaringType, skipEquipmentDictionary: false) | ||||
|     { | ||||
|     } | ||||
|  | ||||
|     [ClassInitialize] | ||||
|     public static void ClassInitialize(TestContext testContext) | ||||
|     { | ||||
|         EAFLoggingUnitTesting ??= new CDE5(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_57_0__CDE5__RsM() | ||||
|     { | ||||
|         string check = "*.RsM"; | ||||
|         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,65 @@ | ||||
| #if v2_57_0 | ||||
| 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_57_0; | ||||
|  | ||||
| [TestClass] | ||||
| public class CDE6_EQPT : EAFLoggingUnitTesting | ||||
| { | ||||
|  | ||||
| #pragma warning disable CA2254 | ||||
| #pragma warning disable IDE0060 | ||||
|  | ||||
|     internal static string DummyRoot { get; private set; } | ||||
|     internal static CDE6_EQPT EAFLoggingUnitTesting { get; private set; } | ||||
|  | ||||
|     static CDE6_EQPT() => DummyRoot = @"\\mesfs.infineon.com\EC_Characterization_Si\Dummy"; | ||||
|  | ||||
|     public CDE6_EQPT() : base(DummyRoot, testContext: null, declaringType: null, skipEquipmentDictionary: false) | ||||
|     { | ||||
|         if (EAFLoggingUnitTesting is null) | ||||
|             throw new Exception(); | ||||
|     } | ||||
|  | ||||
|     public CDE6_EQPT(TestContext testContext) : base(DummyRoot, testContext, new StackFrame().GetMethod().DeclaringType, skipEquipmentDictionary: false) | ||||
|     { | ||||
|     } | ||||
|  | ||||
|     [ClassInitialize] | ||||
|     public static void ClassInitialize(TestContext testContext) | ||||
|     { | ||||
|         EAFLoggingUnitTesting ??= new CDE6_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(); | ||||
|     } | ||||
|  | ||||
| #if DEBUG | ||||
|     [Ignore] | ||||
| #endif | ||||
|     [TestMethod] | ||||
|     public void Production__v2_57_0__CDE6_EQPT__DownloadRsMFile() | ||||
|     { | ||||
|         string check = "CDE_Logs|WaferMeasurementData.log|.RsM"; | ||||
|         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,65 @@ | ||||
| #if v2_57_0 | ||||
| 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_57_0; | ||||
|  | ||||
| [TestClass] | ||||
| public class CDE6 : EAFLoggingUnitTesting | ||||
| { | ||||
|  | ||||
| #pragma warning disable CA2254 | ||||
| #pragma warning disable IDE0060 | ||||
|  | ||||
|     internal static string DummyRoot { get; private set; } | ||||
|     internal static CDE6 EAFLoggingUnitTesting { get; private set; } | ||||
|  | ||||
|     static CDE6() => DummyRoot = @"\\mesfs.infineon.com\EC_Characterization_Si\Dummy"; | ||||
|  | ||||
|     public CDE6() : base(DummyRoot, testContext: null, declaringType: null, skipEquipmentDictionary: false) | ||||
|     { | ||||
|         if (EAFLoggingUnitTesting is null) | ||||
|             throw new Exception(); | ||||
|     } | ||||
|  | ||||
|     public CDE6(TestContext testContext) : base(DummyRoot, testContext, new StackFrame().GetMethod().DeclaringType, skipEquipmentDictionary: false) | ||||
|     { | ||||
|     } | ||||
|  | ||||
|     [ClassInitialize] | ||||
|     public static void ClassInitialize(TestContext testContext) | ||||
|     { | ||||
|         EAFLoggingUnitTesting ??= new CDE6(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_57_0__CDE6__RsM() | ||||
|     { | ||||
|         string check = "*.RsM"; | ||||
|         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,182 @@ | ||||
| #if v2_57_0 | ||||
| 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_57_0; | ||||
|  | ||||
| [TestClass] | ||||
| public class MET08RESIMAPCDE : EAFLoggingUnitTesting | ||||
| { | ||||
|  | ||||
| #pragma warning disable CA2254 | ||||
| #pragma warning disable IDE0060 | ||||
|  | ||||
|     internal static string DummyRoot { get; private set; } | ||||
|     internal static MET08RESIMAPCDE EAFLoggingUnitTesting { get; private set; } | ||||
|  | ||||
|     static MET08RESIMAPCDE() => DummyRoot = @"\\mesfs.infineon.com\EC_Characterization_Si\Dummy"; | ||||
|  | ||||
|     public MET08RESIMAPCDE() : base(DummyRoot, testContext: null, declaringType: null, skipEquipmentDictionary: false) | ||||
|     { | ||||
|         if (EAFLoggingUnitTesting is null) | ||||
|             throw new Exception(); | ||||
|     } | ||||
|  | ||||
|     public MET08RESIMAPCDE(TestContext testContext) : base(DummyRoot, testContext, new StackFrame().GetMethod().DeclaringType, skipEquipmentDictionary: false) | ||||
|     { | ||||
|     } | ||||
|  | ||||
|     [ClassInitialize] | ||||
|     public static void ClassInitialize(TestContext testContext) | ||||
|     { | ||||
|         EAFLoggingUnitTesting ??= new MET08RESIMAPCDE(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_57_0__MET08RESIMAPCDE__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_57_0__MET08RESIMAPCDE__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_57_0__MET08RESIMAPCDE__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_57_0__MET08RESIMAPCDE__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_57_0__MET08RESIMAPCDE__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_57_0__MET08RESIMAPCDE__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_57_0__MET08RESIMAPCDE__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_57_0__MET08RESIMAPCDE__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_57_0__MET08RESIMAPCDE__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_57_0__MET08RESIMAPCDE__Dummy() | ||||
|     { | ||||
|         string check = "637400762024374000.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")); | ||||
|     } | ||||
|  | ||||
| } | ||||
| #endif | ||||
| @ -0,0 +1,65 @@ | ||||
| #if v2_58_0 | ||||
| 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_58_0; | ||||
|  | ||||
| [TestClass] | ||||
| public class CDE4 : EAFLoggingUnitTesting | ||||
| { | ||||
|  | ||||
| #pragma warning disable CA2254 | ||||
| #pragma warning disable IDE0060 | ||||
|  | ||||
|     internal static string DummyRoot { get; private set; } | ||||
|     internal static CDE4 EAFLoggingUnitTesting { get; private set; } | ||||
|  | ||||
|     static CDE4() => DummyRoot = @"\\mesfs.infineon.com\EC_Characterization_Si\Dummy"; | ||||
|  | ||||
|     public CDE4() : base(DummyRoot, testContext: null, declaringType: null, skipEquipmentDictionary: false) | ||||
|     { | ||||
|         if (EAFLoggingUnitTesting is null) | ||||
|             throw new Exception(); | ||||
|     } | ||||
|  | ||||
|     public CDE4(TestContext testContext) : base(DummyRoot, testContext, new StackFrame().GetMethod().DeclaringType, skipEquipmentDictionary: false) | ||||
|     { | ||||
|     } | ||||
|  | ||||
|     [ClassInitialize] | ||||
|     public static void ClassInitialize(TestContext testContext) | ||||
|     { | ||||
|         EAFLoggingUnitTesting ??= new CDE4(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_58_0__CDE4__RsM() | ||||
|     { | ||||
|         string check = "*.RsM"; | ||||
|         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,65 @@ | ||||
| #if v2_58_0 | ||||
| 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_58_0; | ||||
|  | ||||
| [TestClass] | ||||
| public class CDE5_EQPT : EAFLoggingUnitTesting | ||||
| { | ||||
|  | ||||
| #pragma warning disable CA2254 | ||||
| #pragma warning disable IDE0060 | ||||
|  | ||||
|     internal static string DummyRoot { get; private set; } | ||||
|     internal static CDE5_EQPT EAFLoggingUnitTesting { get; private set; } | ||||
|  | ||||
|     static CDE5_EQPT() => DummyRoot = @"\\mesfs.infineon.com\EC_Characterization_Si\Dummy"; | ||||
|  | ||||
|     public CDE5_EQPT() : base(DummyRoot, testContext: null, declaringType: null, skipEquipmentDictionary: false) | ||||
|     { | ||||
|         if (EAFLoggingUnitTesting is null) | ||||
|             throw new Exception(); | ||||
|     } | ||||
|  | ||||
|     public CDE5_EQPT(TestContext testContext) : base(DummyRoot, testContext, new StackFrame().GetMethod().DeclaringType, skipEquipmentDictionary: false) | ||||
|     { | ||||
|     } | ||||
|  | ||||
|     [ClassInitialize] | ||||
|     public static void ClassInitialize(TestContext testContext) | ||||
|     { | ||||
|         EAFLoggingUnitTesting ??= new CDE5_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(); | ||||
|     } | ||||
|  | ||||
| #if DEBUG | ||||
|     [Ignore] | ||||
| #endif | ||||
|     [TestMethod] | ||||
|     public void Production__v2_58_0__CDE5_EQPT__DownloadRsMFile() | ||||
|     { | ||||
|         string check = "CDE_Logs|WaferMeasurementData.log|.RsM"; | ||||
|         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,65 @@ | ||||
| #if v2_58_0 | ||||
| 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_58_0; | ||||
|  | ||||
| [TestClass] | ||||
| public class CDE5 : EAFLoggingUnitTesting | ||||
| { | ||||
|  | ||||
| #pragma warning disable CA2254 | ||||
| #pragma warning disable IDE0060 | ||||
|  | ||||
|     internal static string DummyRoot { get; private set; } | ||||
|     internal static CDE5 EAFLoggingUnitTesting { get; private set; } | ||||
|  | ||||
|     static CDE5() => DummyRoot = @"\\mesfs.infineon.com\EC_Characterization_Si\Dummy"; | ||||
|  | ||||
|     public CDE5() : base(DummyRoot, testContext: null, declaringType: null, skipEquipmentDictionary: false) | ||||
|     { | ||||
|         if (EAFLoggingUnitTesting is null) | ||||
|             throw new Exception(); | ||||
|     } | ||||
|  | ||||
|     public CDE5(TestContext testContext) : base(DummyRoot, testContext, new StackFrame().GetMethod().DeclaringType, skipEquipmentDictionary: false) | ||||
|     { | ||||
|     } | ||||
|  | ||||
|     [ClassInitialize] | ||||
|     public static void ClassInitialize(TestContext testContext) | ||||
|     { | ||||
|         EAFLoggingUnitTesting ??= new CDE5(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_58_0__CDE5__RsM() | ||||
|     { | ||||
|         string check = "*.RsM"; | ||||
|         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,65 @@ | ||||
| #if v2_58_0 | ||||
| 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_58_0; | ||||
|  | ||||
| [TestClass] | ||||
| public class CDE6_EQPT : EAFLoggingUnitTesting | ||||
| { | ||||
|  | ||||
| #pragma warning disable CA2254 | ||||
| #pragma warning disable IDE0060 | ||||
|  | ||||
|     internal static string DummyRoot { get; private set; } | ||||
|     internal static CDE6_EQPT EAFLoggingUnitTesting { get; private set; } | ||||
|  | ||||
|     static CDE6_EQPT() => DummyRoot = @"\\mesfs.infineon.com\EC_Characterization_Si\Dummy"; | ||||
|  | ||||
|     public CDE6_EQPT() : base(DummyRoot, testContext: null, declaringType: null, skipEquipmentDictionary: false) | ||||
|     { | ||||
|         if (EAFLoggingUnitTesting is null) | ||||
|             throw new Exception(); | ||||
|     } | ||||
|  | ||||
|     public CDE6_EQPT(TestContext testContext) : base(DummyRoot, testContext, new StackFrame().GetMethod().DeclaringType, skipEquipmentDictionary: false) | ||||
|     { | ||||
|     } | ||||
|  | ||||
|     [ClassInitialize] | ||||
|     public static void ClassInitialize(TestContext testContext) | ||||
|     { | ||||
|         EAFLoggingUnitTesting ??= new CDE6_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(); | ||||
|     } | ||||
|  | ||||
| #if DEBUG | ||||
|     [Ignore] | ||||
| #endif | ||||
|     [TestMethod] | ||||
|     public void Production__v2_58_0__CDE6_EQPT__DownloadRsMFile() | ||||
|     { | ||||
|         string check = "CDE_Logs|WaferMeasurementData.log|.RsM"; | ||||
|         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,65 @@ | ||||
| #if v2_58_0 | ||||
| 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_58_0; | ||||
|  | ||||
| [TestClass] | ||||
| public class CDE6 : EAFLoggingUnitTesting | ||||
| { | ||||
|  | ||||
| #pragma warning disable CA2254 | ||||
| #pragma warning disable IDE0060 | ||||
|  | ||||
|     internal static string DummyRoot { get; private set; } | ||||
|     internal static CDE6 EAFLoggingUnitTesting { get; private set; } | ||||
|  | ||||
|     static CDE6() => DummyRoot = @"\\mesfs.infineon.com\EC_Characterization_Si\Dummy"; | ||||
|  | ||||
|     public CDE6() : base(DummyRoot, testContext: null, declaringType: null, skipEquipmentDictionary: false) | ||||
|     { | ||||
|         if (EAFLoggingUnitTesting is null) | ||||
|             throw new Exception(); | ||||
|     } | ||||
|  | ||||
|     public CDE6(TestContext testContext) : base(DummyRoot, testContext, new StackFrame().GetMethod().DeclaringType, skipEquipmentDictionary: false) | ||||
|     { | ||||
|     } | ||||
|  | ||||
|     [ClassInitialize] | ||||
|     public static void ClassInitialize(TestContext testContext) | ||||
|     { | ||||
|         EAFLoggingUnitTesting ??= new CDE6(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_58_0__CDE6__RsM() | ||||
|     { | ||||
|         string check = "*.RsM"; | ||||
|         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,182 @@ | ||||
| #if v2_58_0 | ||||
| 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_58_0; | ||||
|  | ||||
| [TestClass] | ||||
| public class MET08RESIMAPCDE : EAFLoggingUnitTesting | ||||
| { | ||||
|  | ||||
| #pragma warning disable CA2254 | ||||
| #pragma warning disable IDE0060 | ||||
|  | ||||
|     internal static string DummyRoot { get; private set; } | ||||
|     internal static MET08RESIMAPCDE EAFLoggingUnitTesting { get; private set; } | ||||
|  | ||||
|     static MET08RESIMAPCDE() => DummyRoot = @"\\mesfs.infineon.com\EC_Characterization_Si\Dummy"; | ||||
|  | ||||
|     public MET08RESIMAPCDE() : base(DummyRoot, testContext: null, declaringType: null, skipEquipmentDictionary: false) | ||||
|     { | ||||
|         if (EAFLoggingUnitTesting is null) | ||||
|             throw new Exception(); | ||||
|     } | ||||
|  | ||||
|     public MET08RESIMAPCDE(TestContext testContext) : base(DummyRoot, testContext, new StackFrame().GetMethod().DeclaringType, skipEquipmentDictionary: false) | ||||
|     { | ||||
|     } | ||||
|  | ||||
|     [ClassInitialize] | ||||
|     public static void ClassInitialize(TestContext testContext) | ||||
|     { | ||||
|         EAFLoggingUnitTesting ??= new MET08RESIMAPCDE(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_58_0__MET08RESIMAPCDE__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_58_0__MET08RESIMAPCDE__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_58_0__MET08RESIMAPCDE__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_58_0__MET08RESIMAPCDE__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_58_0__MET08RESIMAPCDE__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_58_0__MET08RESIMAPCDE__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_58_0__MET08RESIMAPCDE__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_58_0__MET08RESIMAPCDE__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_58_0__MET08RESIMAPCDE__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_58_0__MET08RESIMAPCDE__Dummy() | ||||
|     { | ||||
|         string check = "637400762024374000.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")); | ||||
|     } | ||||
|  | ||||
| } | ||||
| #endif | ||||
| @ -0,0 +1,65 @@ | ||||
| #if v2_59_0 | ||||
| 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_59_0; | ||||
|  | ||||
| [TestClass] | ||||
| public class CDE4 : EAFLoggingUnitTesting | ||||
| { | ||||
|  | ||||
| #pragma warning disable CA2254 | ||||
| #pragma warning disable IDE0060 | ||||
|  | ||||
|     internal static string DummyRoot { get; private set; } | ||||
|     internal static CDE4 EAFLoggingUnitTesting { get; private set; } | ||||
|  | ||||
|     static CDE4() => DummyRoot = @"\\mesfs.infineon.com\EC_Characterization_Si\Dummy"; | ||||
|  | ||||
|     public CDE4() : base(DummyRoot, testContext: null, declaringType: null, skipEquipmentDictionary: false) | ||||
|     { | ||||
|         if (EAFLoggingUnitTesting is null) | ||||
|             throw new Exception(); | ||||
|     } | ||||
|  | ||||
|     public CDE4(TestContext testContext) : base(DummyRoot, testContext, new StackFrame().GetMethod().DeclaringType, skipEquipmentDictionary: false) | ||||
|     { | ||||
|     } | ||||
|  | ||||
|     [ClassInitialize] | ||||
|     public static void ClassInitialize(TestContext testContext) | ||||
|     { | ||||
|         EAFLoggingUnitTesting ??= new CDE4(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_59_0__CDE4__RsM() | ||||
|     { | ||||
|         string check = "*.RsM"; | ||||
|         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,65 @@ | ||||
| #if v2_59_0 | ||||
| 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_59_0; | ||||
|  | ||||
| [TestClass] | ||||
| public class CDE5_EQPT : EAFLoggingUnitTesting | ||||
| { | ||||
|  | ||||
| #pragma warning disable CA2254 | ||||
| #pragma warning disable IDE0060 | ||||
|  | ||||
|     internal static string DummyRoot { get; private set; } | ||||
|     internal static CDE5_EQPT EAFLoggingUnitTesting { get; private set; } | ||||
|  | ||||
|     static CDE5_EQPT() => DummyRoot = @"\\mesfs.infineon.com\EC_Characterization_Si\Dummy"; | ||||
|  | ||||
|     public CDE5_EQPT() : base(DummyRoot, testContext: null, declaringType: null, skipEquipmentDictionary: false) | ||||
|     { | ||||
|         if (EAFLoggingUnitTesting is null) | ||||
|             throw new Exception(); | ||||
|     } | ||||
|  | ||||
|     public CDE5_EQPT(TestContext testContext) : base(DummyRoot, testContext, new StackFrame().GetMethod().DeclaringType, skipEquipmentDictionary: false) | ||||
|     { | ||||
|     } | ||||
|  | ||||
|     [ClassInitialize] | ||||
|     public static void ClassInitialize(TestContext testContext) | ||||
|     { | ||||
|         EAFLoggingUnitTesting ??= new CDE5_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(); | ||||
|     } | ||||
|  | ||||
| #if DEBUG | ||||
|     [Ignore] | ||||
| #endif | ||||
|     [TestMethod] | ||||
|     public void Production__v2_59_0__CDE5_EQPT__DownloadRsMFile() | ||||
|     { | ||||
|         string check = "CDE_Logs|WaferMeasurementData.log|.RsM"; | ||||
|         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,65 @@ | ||||
| #if v2_59_0 | ||||
| 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_59_0; | ||||
|  | ||||
| [TestClass] | ||||
| public class CDE5 : EAFLoggingUnitTesting | ||||
| { | ||||
|  | ||||
| #pragma warning disable CA2254 | ||||
| #pragma warning disable IDE0060 | ||||
|  | ||||
|     internal static string DummyRoot { get; private set; } | ||||
|     internal static CDE5 EAFLoggingUnitTesting { get; private set; } | ||||
|  | ||||
|     static CDE5() => DummyRoot = @"\\mesfs.infineon.com\EC_Characterization_Si\Dummy"; | ||||
|  | ||||
|     public CDE5() : base(DummyRoot, testContext: null, declaringType: null, skipEquipmentDictionary: false) | ||||
|     { | ||||
|         if (EAFLoggingUnitTesting is null) | ||||
|             throw new Exception(); | ||||
|     } | ||||
|  | ||||
|     public CDE5(TestContext testContext) : base(DummyRoot, testContext, new StackFrame().GetMethod().DeclaringType, skipEquipmentDictionary: false) | ||||
|     { | ||||
|     } | ||||
|  | ||||
|     [ClassInitialize] | ||||
|     public static void ClassInitialize(TestContext testContext) | ||||
|     { | ||||
|         EAFLoggingUnitTesting ??= new CDE5(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_59_0__CDE5__RsM() | ||||
|     { | ||||
|         string check = "*.RsM"; | ||||
|         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,65 @@ | ||||
| #if v2_59_0 | ||||
| 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_59_0; | ||||
|  | ||||
| [TestClass] | ||||
| public class CDE6_EQPT : EAFLoggingUnitTesting | ||||
| { | ||||
|  | ||||
| #pragma warning disable CA2254 | ||||
| #pragma warning disable IDE0060 | ||||
|  | ||||
|     internal static string DummyRoot { get; private set; } | ||||
|     internal static CDE6_EQPT EAFLoggingUnitTesting { get; private set; } | ||||
|  | ||||
|     static CDE6_EQPT() => DummyRoot = @"\\mesfs.infineon.com\EC_Characterization_Si\Dummy"; | ||||
|  | ||||
|     public CDE6_EQPT() : base(DummyRoot, testContext: null, declaringType: null, skipEquipmentDictionary: false) | ||||
|     { | ||||
|         if (EAFLoggingUnitTesting is null) | ||||
|             throw new Exception(); | ||||
|     } | ||||
|  | ||||
|     public CDE6_EQPT(TestContext testContext) : base(DummyRoot, testContext, new StackFrame().GetMethod().DeclaringType, skipEquipmentDictionary: false) | ||||
|     { | ||||
|     } | ||||
|  | ||||
|     [ClassInitialize] | ||||
|     public static void ClassInitialize(TestContext testContext) | ||||
|     { | ||||
|         EAFLoggingUnitTesting ??= new CDE6_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(); | ||||
|     } | ||||
|  | ||||
| #if DEBUG | ||||
|     [Ignore] | ||||
| #endif | ||||
|     [TestMethod] | ||||
|     public void Production__v2_59_0__CDE6_EQPT__DownloadRsMFile() | ||||
|     { | ||||
|         string check = "CDE_Logs|WaferMeasurementData.log|.RsM"; | ||||
|         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,65 @@ | ||||
| #if v2_59_0 | ||||
| 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_59_0; | ||||
|  | ||||
| [TestClass] | ||||
| public class CDE6 : EAFLoggingUnitTesting | ||||
| { | ||||
|  | ||||
| #pragma warning disable CA2254 | ||||
| #pragma warning disable IDE0060 | ||||
|  | ||||
|     internal static string DummyRoot { get; private set; } | ||||
|     internal static CDE6 EAFLoggingUnitTesting { get; private set; } | ||||
|  | ||||
|     static CDE6() => DummyRoot = @"\\mesfs.infineon.com\EC_Characterization_Si\Dummy"; | ||||
|  | ||||
|     public CDE6() : base(DummyRoot, testContext: null, declaringType: null, skipEquipmentDictionary: false) | ||||
|     { | ||||
|         if (EAFLoggingUnitTesting is null) | ||||
|             throw new Exception(); | ||||
|     } | ||||
|  | ||||
|     public CDE6(TestContext testContext) : base(DummyRoot, testContext, new StackFrame().GetMethod().DeclaringType, skipEquipmentDictionary: false) | ||||
|     { | ||||
|     } | ||||
|  | ||||
|     [ClassInitialize] | ||||
|     public static void ClassInitialize(TestContext testContext) | ||||
|     { | ||||
|         EAFLoggingUnitTesting ??= new CDE6(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_59_0__CDE6__RsM() | ||||
|     { | ||||
|         string check = "*.RsM"; | ||||
|         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,182 @@ | ||||
| #if v2_59_0 | ||||
| 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_59_0; | ||||
|  | ||||
| [TestClass] | ||||
| public class MET08RESIMAPCDE : EAFLoggingUnitTesting | ||||
| { | ||||
|  | ||||
| #pragma warning disable CA2254 | ||||
| #pragma warning disable IDE0060 | ||||
|  | ||||
|     internal static string DummyRoot { get; private set; } | ||||
|     internal static MET08RESIMAPCDE EAFLoggingUnitTesting { get; private set; } | ||||
|  | ||||
|     static MET08RESIMAPCDE() => DummyRoot = @"\\mesfs.infineon.com\EC_Characterization_Si\Dummy"; | ||||
|  | ||||
|     public MET08RESIMAPCDE() : base(DummyRoot, testContext: null, declaringType: null, skipEquipmentDictionary: false) | ||||
|     { | ||||
|         if (EAFLoggingUnitTesting is null) | ||||
|             throw new Exception(); | ||||
|     } | ||||
|  | ||||
|     public MET08RESIMAPCDE(TestContext testContext) : base(DummyRoot, testContext, new StackFrame().GetMethod().DeclaringType, skipEquipmentDictionary: false) | ||||
|     { | ||||
|     } | ||||
|  | ||||
|     [ClassInitialize] | ||||
|     public static void ClassInitialize(TestContext testContext) | ||||
|     { | ||||
|         EAFLoggingUnitTesting ??= new MET08RESIMAPCDE(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_59_0__MET08RESIMAPCDE__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_59_0__MET08RESIMAPCDE__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_59_0__MET08RESIMAPCDE__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_59_0__MET08RESIMAPCDE__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_59_0__MET08RESIMAPCDE__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_59_0__MET08RESIMAPCDE__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_59_0__MET08RESIMAPCDE__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_59_0__MET08RESIMAPCDE__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_59_0__MET08RESIMAPCDE__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_59_0__MET08RESIMAPCDE__Dummy() | ||||
|     { | ||||
|         string check = "637400762024374000.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")); | ||||
|     } | ||||
|  | ||||
| } | ||||
| #endif | ||||
| @ -7,7 +7,7 @@ using System.Diagnostics; | ||||
| using System.IO; | ||||
| using System.Reflection; | ||||
| 
 | ||||
| namespace Adaptation._Tests.CreateSelfDescription.Staging.v2_57_0; | ||||
| namespace Adaptation._Tests.CreateSelfDescription.Production.v2_60_0; | ||||
| 
 | ||||
| [TestClass] | ||||
| public class CDE4 : EAFLoggingUnitTesting | ||||
| @ -52,7 +52,7 @@ public class CDE4 : EAFLoggingUnitTesting | ||||
|     [Ignore] | ||||
| #endif | ||||
|     [TestMethod] | ||||
|     public void Staging__v2_57_0__CDE4__RsM() | ||||
|     public void Production__v2_60_0__CDE4__RsM() | ||||
|     { | ||||
|         string check = "*.RsM"; | ||||
|         MethodBase methodBase = new StackFrame().GetMethod(); | ||||
| @ -7,7 +7,7 @@ using System.Diagnostics; | ||||
| using System.IO; | ||||
| using System.Reflection; | ||||
| 
 | ||||
| namespace Adaptation._Tests.CreateSelfDescription.Staging.v2_57_0; | ||||
| namespace Adaptation._Tests.CreateSelfDescription.Production.v2_60_0; | ||||
| 
 | ||||
| [TestClass] | ||||
| public class CDE5_EQPT : EAFLoggingUnitTesting | ||||
| @ -52,7 +52,7 @@ public class CDE5_EQPT : EAFLoggingUnitTesting | ||||
|     [Ignore] | ||||
| #endif | ||||
|     [TestMethod] | ||||
|     public void Staging__v2_57_0__CDE5_EQPT__DownloadRsMFile() | ||||
|     public void Production__v2_60_0__CDE5_EQPT__DownloadRsMFile() | ||||
|     { | ||||
|         string check = "CDE_Logs|WaferMeasurementData.log|.RsM"; | ||||
|         MethodBase methodBase = new StackFrame().GetMethod(); | ||||
| @ -7,7 +7,7 @@ using System.Diagnostics; | ||||
| using System.IO; | ||||
| using System.Reflection; | ||||
| 
 | ||||
| namespace Adaptation._Tests.CreateSelfDescription.Staging.v2_57_0; | ||||
| namespace Adaptation._Tests.CreateSelfDescription.Production.v2_60_0; | ||||
| 
 | ||||
| [TestClass] | ||||
| public class CDE5 : EAFLoggingUnitTesting | ||||
| @ -52,7 +52,7 @@ public class CDE5 : EAFLoggingUnitTesting | ||||
|     [Ignore] | ||||
| #endif | ||||
|     [TestMethod] | ||||
|     public void Staging__v2_57_0__CDE5__RsM() | ||||
|     public void Production__v2_60_0__CDE5__RsM() | ||||
|     { | ||||
|         string check = "*.RsM"; | ||||
|         MethodBase methodBase = new StackFrame().GetMethod(); | ||||
| @ -7,7 +7,7 @@ using System.Diagnostics; | ||||
| using System.IO; | ||||
| using System.Reflection; | ||||
| 
 | ||||
| namespace Adaptation._Tests.CreateSelfDescription.Staging.v2_57_0; | ||||
| namespace Adaptation._Tests.CreateSelfDescription.Production.v2_60_0; | ||||
| 
 | ||||
| [TestClass] | ||||
| public class CDE6_EQPT : EAFLoggingUnitTesting | ||||
| @ -52,7 +52,7 @@ public class CDE6_EQPT : EAFLoggingUnitTesting | ||||
|     [Ignore] | ||||
| #endif | ||||
|     [TestMethod] | ||||
|     public void Staging__v2_57_0__CDE6_EQPT__DownloadRsMFile() | ||||
|     public void Production__v2_60_0__CDE6_EQPT__DownloadRsMFile() | ||||
|     { | ||||
|         string check = "CDE_Logs|WaferMeasurementData.log|.RsM"; | ||||
|         MethodBase methodBase = new StackFrame().GetMethod(); | ||||
| @ -7,7 +7,7 @@ using System.Diagnostics; | ||||
| using System.IO; | ||||
| using System.Reflection; | ||||
| 
 | ||||
| namespace Adaptation._Tests.CreateSelfDescription.Staging.v2_57_0; | ||||
| namespace Adaptation._Tests.CreateSelfDescription.Production.v2_60_0; | ||||
| 
 | ||||
| [TestClass] | ||||
| public class CDE6 : EAFLoggingUnitTesting | ||||
| @ -52,7 +52,7 @@ public class CDE6 : EAFLoggingUnitTesting | ||||
|     [Ignore] | ||||
| #endif | ||||
|     [TestMethod] | ||||
|     public void Staging__v2_57_0__CDE6__RsM() | ||||
|     public void Production__v2_60_0__CDE6__RsM() | ||||
|     { | ||||
|         string check = "*.RsM"; | ||||
|         MethodBase methodBase = new StackFrame().GetMethod(); | ||||
| @ -7,7 +7,7 @@ using System.Diagnostics; | ||||
| using System.IO; | ||||
| using System.Reflection; | ||||
| 
 | ||||
| namespace Adaptation._Tests.CreateSelfDescription.Staging.v2_57_0; | ||||
| namespace Adaptation._Tests.CreateSelfDescription.Production.v2_60_0; | ||||
| 
 | ||||
| [TestClass] | ||||
| public class MET08RESIMAPCDE : EAFLoggingUnitTesting | ||||
| @ -52,7 +52,7 @@ public class MET08RESIMAPCDE : EAFLoggingUnitTesting | ||||
|     [Ignore] | ||||
| #endif | ||||
|     [TestMethod] | ||||
|     public void Staging__v2_57_0__MET08RESIMAPCDE__MoveMatchingFiles() | ||||
|     public void Production__v2_60_0__MET08RESIMAPCDE__MoveMatchingFiles() | ||||
|     { | ||||
|         string check = "*.pdsf"; | ||||
|         MethodBase methodBase = new StackFrame().GetMethod(); | ||||
| @ -65,7 +65,7 @@ public class MET08RESIMAPCDE : EAFLoggingUnitTesting | ||||
|     [Ignore] | ||||
| #endif | ||||
|     [TestMethod] | ||||
|     public void Staging__v2_57_0__MET08RESIMAPCDE__OpenInsightMetrologyViewer() | ||||
|     public void Production__v2_60_0__MET08RESIMAPCDE__OpenInsightMetrologyViewer() | ||||
|     { | ||||
|         string check = "*.pdsf"; | ||||
|         MethodBase methodBase = new StackFrame().GetMethod(); | ||||
| @ -78,7 +78,7 @@ public class MET08RESIMAPCDE : EAFLoggingUnitTesting | ||||
|     [Ignore] | ||||
| #endif | ||||
|     [TestMethod] | ||||
|     public void Staging__v2_57_0__MET08RESIMAPCDE__IQSSi() | ||||
|     public void Production__v2_60_0__MET08RESIMAPCDE__IQSSi() | ||||
|     { | ||||
|         string check = "*.pdsf"; | ||||
|         MethodBase methodBase = new StackFrame().GetMethod(); | ||||
| @ -91,7 +91,7 @@ public class MET08RESIMAPCDE : EAFLoggingUnitTesting | ||||
|     [Ignore] | ||||
| #endif | ||||
|     [TestMethod] | ||||
|     public void Staging__v2_57_0__MET08RESIMAPCDE__OpenInsight() | ||||
|     public void Production__v2_60_0__MET08RESIMAPCDE__OpenInsight() | ||||
|     { | ||||
|         string check = "*.pdsf"; | ||||
|         MethodBase methodBase = new StackFrame().GetMethod(); | ||||
| @ -104,7 +104,7 @@ public class MET08RESIMAPCDE : EAFLoggingUnitTesting | ||||
|     [Ignore] | ||||
| #endif | ||||
|     [TestMethod] | ||||
|     public void Staging__v2_57_0__MET08RESIMAPCDE__OpenInsightMetrologyViewerAttachments() | ||||
|     public void Production__v2_60_0__MET08RESIMAPCDE__OpenInsightMetrologyViewerAttachments() | ||||
|     { | ||||
|         string check = "*.pdsf"; | ||||
|         MethodBase methodBase = new StackFrame().GetMethod(); | ||||
| @ -117,7 +117,7 @@ public class MET08RESIMAPCDE : EAFLoggingUnitTesting | ||||
|     [Ignore] | ||||
| #endif | ||||
|     [TestMethod] | ||||
|     public void Staging__v2_57_0__MET08RESIMAPCDE__APC() | ||||
|     public void Production__v2_60_0__MET08RESIMAPCDE__APC() | ||||
|     { | ||||
|         string check = "*.pdsf"; | ||||
|         MethodBase methodBase = new StackFrame().GetMethod(); | ||||
| @ -130,7 +130,7 @@ public class MET08RESIMAPCDE : EAFLoggingUnitTesting | ||||
|     [Ignore] | ||||
| #endif | ||||
|     [TestMethod] | ||||
|     public void Staging__v2_57_0__MET08RESIMAPCDE__SPaCe() | ||||
|     public void Production__v2_60_0__MET08RESIMAPCDE__SPaCe() | ||||
|     { | ||||
|         string check = "*.pdsf"; | ||||
|         MethodBase methodBase = new StackFrame().GetMethod(); | ||||
| @ -143,7 +143,7 @@ public class MET08RESIMAPCDE : EAFLoggingUnitTesting | ||||
|     [Ignore] | ||||
| #endif | ||||
|     [TestMethod] | ||||
|     public void Staging__v2_57_0__MET08RESIMAPCDE__Processed() | ||||
|     public void Production__v2_60_0__MET08RESIMAPCDE__Processed() | ||||
|     { | ||||
|         string check = "*.pdsf"; | ||||
|         MethodBase methodBase = new StackFrame().GetMethod(); | ||||
| @ -156,7 +156,7 @@ public class MET08RESIMAPCDE : EAFLoggingUnitTesting | ||||
|     [Ignore] | ||||
| #endif | ||||
|     [TestMethod] | ||||
|     public void Staging__v2_57_0__MET08RESIMAPCDE__Archive() | ||||
|     public void Production__v2_60_0__MET08RESIMAPCDE__Archive() | ||||
|     { | ||||
|         string check = "*.pdsf"; | ||||
|         MethodBase methodBase = new StackFrame().GetMethod(); | ||||
| @ -169,7 +169,7 @@ public class MET08RESIMAPCDE : EAFLoggingUnitTesting | ||||
|     [Ignore] | ||||
| #endif | ||||
|     [TestMethod] | ||||
|     public void Staging__v2_57_0__MET08RESIMAPCDE__Dummy() | ||||
|     public void Production__v2_60_0__MET08RESIMAPCDE__Dummy() | ||||
|     { | ||||
|         string check = "637400762024374000.zip"; | ||||
|         MethodBase methodBase = new StackFrame().GetMethod(); | ||||
| @ -6,7 +6,7 @@ using System; | ||||
| using System.Diagnostics; | ||||
| using System.Reflection; | ||||
| 
 | ||||
| namespace Adaptation._Tests.Extract.Staging.v2_57_0; | ||||
| namespace Adaptation._Tests.Extract.Production.v2_57_0; | ||||
| 
 | ||||
| [TestClass] | ||||
| public class CDE4 | ||||
| @ -15,35 +15,34 @@ public class CDE4 | ||||
| #pragma warning disable CA2254 | ||||
| #pragma warning disable IDE0060 | ||||
| 
 | ||||
|     private static CreateSelfDescription.Staging.v2_57_0.CDE4 _CDE4; | ||||
|     private static CreateSelfDescription.Production.v2_57_0.CDE4 _CDE4; | ||||
| 
 | ||||
|     [ClassInitialize] | ||||
|     public static void ClassInitialize(TestContext testContext) | ||||
|     { | ||||
|         CreateSelfDescription.Staging.v2_57_0.CDE4.ClassInitialize(testContext); | ||||
|         _CDE4 = CreateSelfDescription.Staging.v2_57_0.CDE4.EAFLoggingUnitTesting; | ||||
|         CreateSelfDescription.Production.v2_57_0.CDE4.ClassInitialize(testContext); | ||||
|         _CDE4 = CreateSelfDescription.Production.v2_57_0.CDE4.EAFLoggingUnitTesting; | ||||
|     } | ||||
| 
 | ||||
| #if DEBUG | ||||
|     [Ignore] | ||||
| #endif | ||||
|     [TestMethod] | ||||
|     public void Staging__v2_57_0__CDE4__RsM() => _CDE4.Staging__v2_57_0__CDE4__RsM(); | ||||
|     public void Production__v2_57_0__CDE4__RsM() => _CDE4.Production__v2_57_0__CDE4__RsM(); | ||||
| 
 | ||||
| #if DEBUG | ||||
|     [Ignore] | ||||
| #endif | ||||
|     [TestMethod] | ||||
|     public void Staging__v2_57_0__CDE4__RsM637919422210000000__Normal() | ||||
|     public void Production__v2_57_0__CDE4__RsM637919422210000000__Normal() | ||||
|     { | ||||
|         DateTime dateTime; | ||||
|         string check = "*.RsM"; | ||||
|         _CDE4.Staging__v2_57_0__CDE4__RsM(); | ||||
|         _CDE4.Production__v2_57_0__CDE4__RsM(); | ||||
|         MethodBase methodBase = new StackFrame().GetMethod(); | ||||
|         string[] variables = _CDE4.AdaptationTesting.GetVariables(methodBase, check, validatePDSF: false); | ||||
|         IFileRead fileRead = _CDE4.AdaptationTesting.Get(methodBase, sourceFileLocation: variables[2], sourceFileFilter: variables[3], useCyclicalForDescription: false); | ||||
|         Logistics logistics = new(fileRead); | ||||
| 
 | ||||
|         _ = Shared.AdaptationTesting.ReExtractCompareUpdatePassDirectory(variables, fileRead, logistics, validatePDSF: false); | ||||
|         dateTime = FileHandlers.RsM.ProcessData.GetDateTime(logistics, string.Empty); | ||||
|         Assert.IsTrue(dateTime == logistics.DateTimeFromSequence); | ||||
							
								
								
									
										29
									
								
								Adaptation/_Tests/Extract/Production/v2.57.0/CDE5-EQPT.cs
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										29
									
								
								Adaptation/_Tests/Extract/Production/v2.57.0/CDE5-EQPT.cs
									
									
									
									
									
										Normal file
									
								
							| @ -0,0 +1,29 @@ | ||||
| #if v2_57_0 | ||||
| using Microsoft.VisualStudio.TestTools.UnitTesting; | ||||
|  | ||||
| namespace Adaptation._Tests.Extract.Production.v2_57_0; | ||||
|  | ||||
| [TestClass] | ||||
| public class CDE5_EQPT | ||||
| { | ||||
|  | ||||
| #pragma warning disable CA2254 | ||||
| #pragma warning disable IDE0060 | ||||
|  | ||||
|     private static CreateSelfDescription.Production.v2_57_0.CDE5_EQPT _CDE5_EQPT; | ||||
|  | ||||
|     [ClassInitialize] | ||||
|     public static void ClassInitialize(TestContext testContext) | ||||
|     { | ||||
|         CreateSelfDescription.Production.v2_57_0.CDE5_EQPT.ClassInitialize(testContext); | ||||
|         _CDE5_EQPT = CreateSelfDescription.Production.v2_57_0.CDE5_EQPT.EAFLoggingUnitTesting; | ||||
|     } | ||||
|  | ||||
| #if DEBUG | ||||
|     [Ignore] | ||||
| #endif | ||||
|     [TestMethod] | ||||
|     public void Production__v2_57_0__CDE5_EQPT__DownloadRsMFile() => _CDE5_EQPT.Production__v2_57_0__CDE5_EQPT__DownloadRsMFile(); | ||||
|  | ||||
| } | ||||
| #endif | ||||
| @ -6,7 +6,7 @@ using System; | ||||
| using System.Diagnostics; | ||||
| using System.Reflection; | ||||
| 
 | ||||
| namespace Adaptation._Tests.Extract.Staging.v2_57_0; | ||||
| namespace Adaptation._Tests.Extract.Production.v2_57_0; | ||||
| 
 | ||||
| [TestClass] | ||||
| public class CDE5 | ||||
| @ -15,13 +15,13 @@ public class CDE5 | ||||
| #pragma warning disable CA2254 | ||||
| #pragma warning disable IDE0060 | ||||
| 
 | ||||
|     private static CreateSelfDescription.Staging.v2_57_0.CDE5 _CDE5; | ||||
|     private static CreateSelfDescription.Production.v2_57_0.CDE5 _CDE5; | ||||
| 
 | ||||
|     [ClassInitialize] | ||||
|     public static void ClassInitialize(TestContext testContext) | ||||
|     { | ||||
|         CreateSelfDescription.Staging.v2_57_0.CDE5.ClassInitialize(testContext); | ||||
|         _CDE5 = CreateSelfDescription.Staging.v2_57_0.CDE5.EAFLoggingUnitTesting; | ||||
|         CreateSelfDescription.Production.v2_57_0.CDE5.ClassInitialize(testContext); | ||||
|         _CDE5 = CreateSelfDescription.Production.v2_57_0.CDE5.EAFLoggingUnitTesting; | ||||
|     } | ||||
| 
 | ||||
|     private static void NonThrowTryCatch() | ||||
| @ -35,18 +35,18 @@ public class CDE5 | ||||
|     [Ignore] | ||||
| #endif | ||||
|     [TestMethod] | ||||
|     public void Staging__v2_57_0__CDE5__RsM() => _CDE5.Staging__v2_57_0__CDE5__RsM(); | ||||
|     public void Production__v2_57_0__CDE5__RsM() => _CDE5.Production__v2_57_0__CDE5__RsM(); | ||||
| 
 | ||||
| #if DEBUG | ||||
|     [Ignore] | ||||
| #endif | ||||
|     [TestMethod] | ||||
|     public void Staging__v2_57_0__CDE5__RsM637952212190000000__Normal() | ||||
|     public void Production__v2_57_0__CDE5__RsM637952212190000000__Normal() | ||||
|     { | ||||
|         DateTime dateTime; | ||||
|         string check = "*.RsM"; | ||||
|         bool validatePDSF = false; | ||||
|         _CDE5.Staging__v2_57_0__CDE5__RsM(); | ||||
|         _CDE5.Production__v2_57_0__CDE5__RsM(); | ||||
|         MethodBase methodBase = new StackFrame().GetMethod(); | ||||
|         Assert.IsFalse(string.IsNullOrEmpty(_CDE5.AdaptationTesting.TestContext.FullyQualifiedTestClassName)); | ||||
|         string[] variables = _CDE5.AdaptationTesting.GetVariables(methodBase, check, validatePDSF); | ||||
| @ -64,11 +64,11 @@ public class CDE5 | ||||
|     [Ignore] | ||||
| #endif | ||||
|     [TestMethod] | ||||
|     public void Staging__v2_57_0__CDE5__RsM638181148290431160__WMO() | ||||
|     public void Production__v2_57_0__CDE5__RsM638181148290431160__WMO() | ||||
|     { | ||||
|         string check = "*.RsM"; | ||||
|         bool validatePDSF = false; | ||||
|         _CDE5.Staging__v2_57_0__CDE5__RsM(); | ||||
|         _CDE5.Production__v2_57_0__CDE5__RsM(); | ||||
|         MethodBase methodBase = new StackFrame().GetMethod(); | ||||
|         Assert.IsFalse(string.IsNullOrEmpty(_CDE5.AdaptationTesting.TestContext.FullyQualifiedTestClassName)); | ||||
|         string[] variables = _CDE5.AdaptationTesting.GetVariables(methodBase, check, validatePDSF); | ||||
| @ -4,7 +4,7 @@ using System.Diagnostics; | ||||
| using System.Reflection; | ||||
| using System.Threading; | ||||
| 
 | ||||
| namespace Adaptation._Tests.Extract.Staging.v2_57_0; | ||||
| namespace Adaptation._Tests.Extract.Production.v2_57_0; | ||||
| 
 | ||||
| [TestClass] | ||||
| public class CDE6_EQPT | ||||
| @ -13,29 +13,29 @@ public class CDE6_EQPT | ||||
| #pragma warning disable CA2254 | ||||
| #pragma warning disable IDE0060 | ||||
| 
 | ||||
|     private static CreateSelfDescription.Staging.v2_57_0.CDE6_EQPT _CDE6_EQPT; | ||||
|     private static CreateSelfDescription.Production.v2_57_0.CDE6_EQPT _CDE6_EQPT; | ||||
| 
 | ||||
|     [ClassInitialize] | ||||
|     public static void ClassInitialize(TestContext testContext) | ||||
|     { | ||||
|         CreateSelfDescription.Staging.v2_57_0.CDE6_EQPT.ClassInitialize(testContext); | ||||
|         _CDE6_EQPT = CreateSelfDescription.Staging.v2_57_0.CDE6_EQPT.EAFLoggingUnitTesting; | ||||
|         CreateSelfDescription.Production.v2_57_0.CDE6_EQPT.ClassInitialize(testContext); | ||||
|         _CDE6_EQPT = CreateSelfDescription.Production.v2_57_0.CDE6_EQPT.EAFLoggingUnitTesting; | ||||
|     } | ||||
| 
 | ||||
| #if DEBUG | ||||
|     [Ignore] | ||||
| #endif | ||||
|     [TestMethod] | ||||
|     public void Staging__v2_57_0__CDE6_EQPT__DownloadRsMFile() => _CDE6_EQPT.Staging__v2_57_0__CDE6_EQPT__DownloadRsMFile(); | ||||
|     public void Production__v2_57_0__CDE6_EQPT__DownloadRsMFile() => _CDE6_EQPT.Production__v2_57_0__CDE6_EQPT__DownloadRsMFile(); | ||||
| 
 | ||||
|     [Ignore] | ||||
|     [TestMethod] | ||||
|     public void Staging__v2_57_0__CDE6_EQPT__DownloadRsMFile638065099250000000__Normal() | ||||
|     public void Production__v2_57_0__CDE6_EQPT__DownloadRsMFile638065099250000000__Normal() | ||||
|     { | ||||
|         bool validatePDSF = false; | ||||
|         string check = "CDE_Logs|WaferMeasurementData.log|.RsM"; | ||||
|         MethodBase methodBase = new StackFrame().GetMethod(); | ||||
|         _CDE6_EQPT.Staging__v2_57_0__CDE6_EQPT__DownloadRsMFile(); | ||||
|         _CDE6_EQPT.Production__v2_57_0__CDE6_EQPT__DownloadRsMFile(); | ||||
|         _ = _CDE6_EQPT.AdaptationTesting.GetVariables(methodBase, check, validatePDSF); | ||||
|         for (int i = 0; i < int.MaxValue; i++) | ||||
|             Thread.Sleep(500); | ||||
| @ -6,7 +6,7 @@ using System; | ||||
| using System.Diagnostics; | ||||
| using System.Reflection; | ||||
| 
 | ||||
| namespace Adaptation._Tests.Extract.Staging.v2_57_0; | ||||
| namespace Adaptation._Tests.Extract.Production.v2_57_0; | ||||
| 
 | ||||
| [TestClass] | ||||
| public class CDE6 | ||||
| @ -15,31 +15,31 @@ public class CDE6 | ||||
| #pragma warning disable CA2254 | ||||
| #pragma warning disable IDE0060 | ||||
| 
 | ||||
|     private static CreateSelfDescription.Staging.v2_57_0.CDE6 _CDE6; | ||||
|     private static CreateSelfDescription.Production.v2_57_0.CDE6 _CDE6; | ||||
| 
 | ||||
|     [ClassInitialize] | ||||
|     public static void ClassInitialize(TestContext testContext) | ||||
|     { | ||||
|         CreateSelfDescription.Staging.v2_57_0.CDE6.ClassInitialize(testContext); | ||||
|         _CDE6 = CreateSelfDescription.Staging.v2_57_0.CDE6.EAFLoggingUnitTesting; | ||||
|         CreateSelfDescription.Production.v2_57_0.CDE6.ClassInitialize(testContext); | ||||
|         _CDE6 = CreateSelfDescription.Production.v2_57_0.CDE6.EAFLoggingUnitTesting; | ||||
|     } | ||||
| 
 | ||||
| #if DEBUG | ||||
|     [Ignore] | ||||
| #endif | ||||
|     [TestMethod] | ||||
|     public void Staging__v2_57_0__CDE6__RsM() => _CDE6.Staging__v2_57_0__CDE6__RsM(); | ||||
|     public void Production__v2_57_0__CDE6__RsM() => _CDE6.Production__v2_57_0__CDE6__RsM(); | ||||
| 
 | ||||
| #if DEBUG | ||||
|     [Ignore] | ||||
| #endif | ||||
|     [TestMethod] | ||||
|     public void Staging__v2_57_0__CDE6__RsM638065099250000000__Normal() | ||||
|     public void Production__v2_57_0__CDE6__RsM638065099250000000__Normal() | ||||
|     { | ||||
|         DateTime dateTime; | ||||
|         string check = "*.RsM"; | ||||
|         bool validatePDSF = false; | ||||
|         _CDE6.Staging__v2_57_0__CDE6__RsM(); | ||||
|         _CDE6.Production__v2_57_0__CDE6__RsM(); | ||||
|         MethodBase methodBase = new StackFrame().GetMethod(); | ||||
|         Assert.IsFalse(string.IsNullOrEmpty(_CDE6.AdaptationTesting.TestContext.FullyQualifiedTestClassName)); | ||||
|         string[] variables = _CDE6.AdaptationTesting.GetVariables(methodBase, check, validatePDSF); | ||||
| @ -1,4 +1,4 @@ | ||||
| #if true | ||||
| #if v2_57_0 | ||||
| using Adaptation._Tests.Shared; | ||||
| using Adaptation.Shared; | ||||
| using Adaptation.Shared.Methods; | ||||
| @ -7,7 +7,7 @@ using System; | ||||
| using System.Diagnostics; | ||||
| using System.Reflection; | ||||
| 
 | ||||
| namespace Adaptation._Tests.Extract.Staging.v2_57_0; | ||||
| namespace Adaptation._Tests.Extract.Production.v2_57_0; | ||||
| 
 | ||||
| [TestClass] | ||||
| public class MET08RESIMAPCDE | ||||
| @ -16,13 +16,13 @@ public class MET08RESIMAPCDE | ||||
| #pragma warning disable CA2254 | ||||
| #pragma warning disable IDE0060 | ||||
| 
 | ||||
|     private static CreateSelfDescription.Staging.v2_57_0.MET08RESIMAPCDE _MET08RESIMAPCDE; | ||||
|     private static CreateSelfDescription.Production.v2_57_0.MET08RESIMAPCDE _MET08RESIMAPCDE; | ||||
| 
 | ||||
|     [ClassInitialize] | ||||
|     public static void ClassInitialize(TestContext testContext) | ||||
|     { | ||||
|         CreateSelfDescription.Staging.v2_57_0.MET08RESIMAPCDE.ClassInitialize(testContext); | ||||
|         _MET08RESIMAPCDE = CreateSelfDescription.Staging.v2_57_0.MET08RESIMAPCDE.EAFLoggingUnitTesting; | ||||
|         CreateSelfDescription.Production.v2_57_0.MET08RESIMAPCDE.ClassInitialize(testContext); | ||||
|         _MET08RESIMAPCDE = CreateSelfDescription.Production.v2_57_0.MET08RESIMAPCDE.EAFLoggingUnitTesting; | ||||
|     } | ||||
| 
 | ||||
|     private static void NonThrowTryCatch() | ||||
| @ -36,18 +36,18 @@ public class MET08RESIMAPCDE | ||||
|     [Ignore] | ||||
| #endif | ||||
|     [TestMethod] | ||||
|     public void Staging__v2_57_0__MET08RESIMAPCDE__MoveMatchingFiles() => _MET08RESIMAPCDE.Staging__v2_57_0__MET08RESIMAPCDE__MoveMatchingFiles(); | ||||
|     public void Production__v2_57_0__MET08RESIMAPCDE__MoveMatchingFiles() => _MET08RESIMAPCDE.Production__v2_57_0__MET08RESIMAPCDE__MoveMatchingFiles(); | ||||
| 
 | ||||
| #if DEBUG | ||||
|     [Ignore] | ||||
| #endif | ||||
|     [TestMethod] | ||||
|     public void Staging__v2_57_0__MET08RESIMAPCDE__MoveMatchingFiles637953064190000000__Normal() | ||||
|     public void Production__v2_57_0__MET08RESIMAPCDE__MoveMatchingFiles637953064190000000__Normal() | ||||
|     { | ||||
|         DateTime dateTime; | ||||
|         string check = "*"; | ||||
|         bool validatePDSF = false; | ||||
|         _MET08RESIMAPCDE.Staging__v2_57_0__MET08RESIMAPCDE__MoveMatchingFiles(); | ||||
|         _MET08RESIMAPCDE.Production__v2_57_0__MET08RESIMAPCDE__MoveMatchingFiles(); | ||||
|         MethodBase methodBase = new StackFrame().GetMethod(); | ||||
|         Assert.IsFalse(string.IsNullOrEmpty(_MET08RESIMAPCDE.AdaptationTesting.TestContext.FullyQualifiedTestClassName)); | ||||
|         string[] variables = _MET08RESIMAPCDE.AdaptationTesting.GetVariables(methodBase, check, validatePDSF); | ||||
| @ -64,17 +64,17 @@ public class MET08RESIMAPCDE | ||||
|     [Ignore] | ||||
| #endif | ||||
|     [TestMethod] | ||||
|     public void Staging__v2_57_0__MET08RESIMAPCDE__OpenInsightMetrologyViewer() => _MET08RESIMAPCDE.Staging__v2_57_0__MET08RESIMAPCDE__OpenInsightMetrologyViewer(); | ||||
|     public void Production__v2_57_0__MET08RESIMAPCDE__OpenInsightMetrologyViewer() => _MET08RESIMAPCDE.Production__v2_57_0__MET08RESIMAPCDE__OpenInsightMetrologyViewer(); | ||||
| 
 | ||||
| #if DEBUG | ||||
|     [Ignore] | ||||
| #endif | ||||
|     [TestMethod] | ||||
|     public void Staging__v2_57_0__MET08RESIMAPCDE__OpenInsightMetrologyViewer638127615724700306__NewColumn() | ||||
|     public void Production__v2_57_0__MET08RESIMAPCDE__OpenInsightMetrologyViewer638127615724700306__NewColumn() | ||||
|     { | ||||
|         string check = "*.pdsf"; | ||||
|         MethodBase methodBase = new StackFrame().GetMethod(); | ||||
|         _MET08RESIMAPCDE.Staging__v2_57_0__MET08RESIMAPCDE__OpenInsightMetrologyViewer(); | ||||
|         _MET08RESIMAPCDE.Production__v2_57_0__MET08RESIMAPCDE__OpenInsightMetrologyViewer(); | ||||
|         string[] variables = _MET08RESIMAPCDE.AdaptationTesting.GetVariables(methodBase, check, validatePDSF: false); | ||||
|         IFileRead fileRead = _MET08RESIMAPCDE.AdaptationTesting.Get(methodBase, sourceFileLocation: variables[2], sourceFileFilter: variables[3], useCyclicalForDescription: false); | ||||
|         Logistics logistics = new(fileRead); | ||||
| @ -85,23 +85,23 @@ public class MET08RESIMAPCDE | ||||
|     [Ignore] | ||||
| #endif | ||||
|     [TestMethod] | ||||
|     public void Staging__v2_57_0__MET08RESIMAPCDE__IQSSi() => _MET08RESIMAPCDE.Staging__v2_57_0__MET08RESIMAPCDE__IQSSi(); | ||||
|     public void Production__v2_57_0__MET08RESIMAPCDE__IQSSi() => _MET08RESIMAPCDE.Production__v2_57_0__MET08RESIMAPCDE__IQSSi(); | ||||
| 
 | ||||
| #if DEBUG | ||||
|     [Ignore] | ||||
| #endif | ||||
|     [TestMethod] | ||||
|     public void Staging__v2_57_0__MET08RESIMAPCDE__OpenInsight() => _MET08RESIMAPCDE.Staging__v2_57_0__MET08RESIMAPCDE__OpenInsight(); | ||||
|     public void Production__v2_57_0__MET08RESIMAPCDE__OpenInsight() => _MET08RESIMAPCDE.Production__v2_57_0__MET08RESIMAPCDE__OpenInsight(); | ||||
| 
 | ||||
| #if DEBUG | ||||
|     [Ignore] | ||||
| #endif | ||||
|     [TestMethod] | ||||
|     public void Staging__v2_57_0__MET08RESIMAPCDE__OpenInsight638054501710000000__IqsSql() | ||||
|     public void Production__v2_57_0__MET08RESIMAPCDE__OpenInsight638054501710000000__IqsSql() | ||||
|     { | ||||
|         string check = "*.pdsf"; | ||||
|         MethodBase methodBase = new StackFrame().GetMethod(); | ||||
|         _MET08RESIMAPCDE.Staging__v2_57_0__MET08RESIMAPCDE__OpenInsight(); | ||||
|         _MET08RESIMAPCDE.Production__v2_57_0__MET08RESIMAPCDE__OpenInsight(); | ||||
|         string[] variables = _MET08RESIMAPCDE.AdaptationTesting.GetVariables(methodBase, check, validatePDSF: false); | ||||
|         IFileRead fileRead = _MET08RESIMAPCDE.AdaptationTesting.Get(methodBase, sourceFileLocation: variables[2], sourceFileFilter: variables[3], useCyclicalForDescription: false); | ||||
|         Logistics logistics = new(fileRead); | ||||
| @ -112,11 +112,11 @@ public class MET08RESIMAPCDE | ||||
|     [Ignore] | ||||
| #endif | ||||
|     [TestMethod] | ||||
|     public void Staging__v2_57_0__MET08RESIMAPCDE__OpenInsight638116271690000000__IqsSql() | ||||
|     public void Production__v2_57_0__MET08RESIMAPCDE__OpenInsight638116271690000000__IqsSql() | ||||
|     { | ||||
|         string check = "*.pdsf"; | ||||
|         MethodBase methodBase = new StackFrame().GetMethod(); | ||||
|         _MET08RESIMAPCDE.Staging__v2_57_0__MET08RESIMAPCDE__OpenInsight(); | ||||
|         _MET08RESIMAPCDE.Production__v2_57_0__MET08RESIMAPCDE__OpenInsight(); | ||||
|         string[] variables = _MET08RESIMAPCDE.AdaptationTesting.GetVariables(methodBase, check, validatePDSF: false); | ||||
|         IFileRead fileRead = _MET08RESIMAPCDE.AdaptationTesting.Get(methodBase, sourceFileLocation: variables[2], sourceFileFilter: variables[3], useCyclicalForDescription: false); | ||||
|         Logistics logistics = new(fileRead); | ||||
| @ -127,11 +127,11 @@ public class MET08RESIMAPCDE | ||||
|     [Ignore] | ||||
| #endif | ||||
|     [TestMethod] | ||||
|     public void Staging__v2_57_0__MET08RESIMAPCDE__OpenInsight638159693274771954__IqsSqlButSplit() | ||||
|     public void Production__v2_57_0__MET08RESIMAPCDE__OpenInsight638159693274771954__IqsSqlButSplit() | ||||
|     { | ||||
|         string check = "*.pdsf"; | ||||
|         MethodBase methodBase = new StackFrame().GetMethod(); | ||||
|         _MET08RESIMAPCDE.Staging__v2_57_0__MET08RESIMAPCDE__OpenInsight(); | ||||
|         _MET08RESIMAPCDE.Production__v2_57_0__MET08RESIMAPCDE__OpenInsight(); | ||||
|         string[] variables = _MET08RESIMAPCDE.AdaptationTesting.GetVariables(methodBase, check, validatePDSF: false); | ||||
|         IFileRead fileRead = _MET08RESIMAPCDE.AdaptationTesting.Get(methodBase, sourceFileLocation: variables[2], sourceFileFilter: variables[3], useCyclicalForDescription: false); | ||||
|         Logistics logistics = new(fileRead); | ||||
| @ -143,37 +143,37 @@ public class MET08RESIMAPCDE | ||||
|     [Ignore] | ||||
| #endif | ||||
|     [TestMethod] | ||||
|     public void Staging__v2_57_0__MET08RESIMAPCDE__OpenInsightMetrologyViewerAttachments() => _MET08RESIMAPCDE.Staging__v2_57_0__MET08RESIMAPCDE__OpenInsightMetrologyViewerAttachments(); | ||||
|     public void Production__v2_57_0__MET08RESIMAPCDE__OpenInsightMetrologyViewerAttachments() => _MET08RESIMAPCDE.Production__v2_57_0__MET08RESIMAPCDE__OpenInsightMetrologyViewerAttachments(); | ||||
| 
 | ||||
| #if DEBUG | ||||
|     [Ignore] | ||||
| #endif | ||||
|     [TestMethod] | ||||
|     public void Staging__v2_57_0__MET08RESIMAPCDE__APC() => _MET08RESIMAPCDE.Staging__v2_57_0__MET08RESIMAPCDE__APC(); | ||||
|     public void Production__v2_57_0__MET08RESIMAPCDE__APC() => _MET08RESIMAPCDE.Production__v2_57_0__MET08RESIMAPCDE__APC(); | ||||
| 
 | ||||
| #if DEBUG | ||||
|     [Ignore] | ||||
| #endif | ||||
|     [TestMethod] | ||||
|     public void Staging__v2_57_0__MET08RESIMAPCDE__SPaCe() => _MET08RESIMAPCDE.Staging__v2_57_0__MET08RESIMAPCDE__SPaCe(); | ||||
|     public void Production__v2_57_0__MET08RESIMAPCDE__SPaCe() => _MET08RESIMAPCDE.Production__v2_57_0__MET08RESIMAPCDE__SPaCe(); | ||||
| 
 | ||||
| #if DEBUG | ||||
|     [Ignore] | ||||
| #endif | ||||
|     [TestMethod] | ||||
|     public void Staging__v2_57_0__MET08RESIMAPCDE__Processed() => _MET08RESIMAPCDE.Staging__v2_57_0__MET08RESIMAPCDE__Processed(); | ||||
|     public void Production__v2_57_0__MET08RESIMAPCDE__Processed() => _MET08RESIMAPCDE.Production__v2_57_0__MET08RESIMAPCDE__Processed(); | ||||
| 
 | ||||
| #if DEBUG | ||||
|     [Ignore] | ||||
| #endif | ||||
|     [TestMethod] | ||||
|     public void Staging__v2_57_0__MET08RESIMAPCDE__Archive() => _MET08RESIMAPCDE.Staging__v2_57_0__MET08RESIMAPCDE__Archive(); | ||||
|     public void Production__v2_57_0__MET08RESIMAPCDE__Archive() => _MET08RESIMAPCDE.Production__v2_57_0__MET08RESIMAPCDE__Archive(); | ||||
| 
 | ||||
| #if DEBUG | ||||
|     [Ignore] | ||||
| #endif | ||||
|     [TestMethod] | ||||
|     public void Staging__v2_57_0__MET08RESIMAPCDE__Dummy() => _MET08RESIMAPCDE.Staging__v2_57_0__MET08RESIMAPCDE__Dummy(); | ||||
|     public void Production__v2_57_0__MET08RESIMAPCDE__Dummy() => _MET08RESIMAPCDE.Production__v2_57_0__MET08RESIMAPCDE__Dummy(); | ||||
| 
 | ||||
| } | ||||
| #endif | ||||
							
								
								
									
										54
									
								
								Adaptation/_Tests/Extract/Production/v2.58.0/CDE4.cs
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										54
									
								
								Adaptation/_Tests/Extract/Production/v2.58.0/CDE4.cs
									
									
									
									
									
										Normal file
									
								
							| @ -0,0 +1,54 @@ | ||||
| #if v2_58_0 | ||||
| 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_58_0; | ||||
|  | ||||
| [TestClass] | ||||
| public class CDE4 | ||||
| { | ||||
|  | ||||
| #pragma warning disable CA2254 | ||||
| #pragma warning disable IDE0060 | ||||
|  | ||||
|     private static CreateSelfDescription.Production.v2_58_0.CDE4 _CDE4; | ||||
|  | ||||
|     [ClassInitialize] | ||||
|     public static void ClassInitialize(TestContext testContext) | ||||
|     { | ||||
|         CreateSelfDescription.Production.v2_58_0.CDE4.ClassInitialize(testContext); | ||||
|         _CDE4 = CreateSelfDescription.Production.v2_58_0.CDE4.EAFLoggingUnitTesting; | ||||
|     } | ||||
|  | ||||
| #if DEBUG | ||||
|     [Ignore] | ||||
| #endif | ||||
|     [TestMethod] | ||||
|     public void Production__v2_58_0__CDE4__RsM() => _CDE4.Production__v2_58_0__CDE4__RsM(); | ||||
|  | ||||
| #if DEBUG | ||||
|     [Ignore] | ||||
| #endif | ||||
|     [TestMethod] | ||||
|     public void Production__v2_58_0__CDE4__RsM637919422210000000__Normal() | ||||
|     { | ||||
|         DateTime dateTime; | ||||
|         string check = "*.RsM"; | ||||
|         _CDE4.Production__v2_58_0__CDE4__RsM(); | ||||
|         MethodBase methodBase = new StackFrame().GetMethod(); | ||||
|         string[] variables = _CDE4.AdaptationTesting.GetVariables(methodBase, check, validatePDSF: false); | ||||
|         IFileRead fileRead = _CDE4.AdaptationTesting.Get(methodBase, sourceFileLocation: variables[2], sourceFileFilter: variables[3], useCyclicalForDescription: false); | ||||
|         Logistics logistics = new(fileRead); | ||||
|         _ = Shared.AdaptationTesting.ReExtractCompareUpdatePassDirectory(variables, fileRead, logistics, validatePDSF: false); | ||||
|         dateTime = FileHandlers.RsM.ProcessData.GetDateTime(logistics, string.Empty); | ||||
|         Assert.IsTrue(dateTime == logistics.DateTimeFromSequence); | ||||
|         dateTime = FileHandlers.RsM.ProcessData.GetDateTime(logistics, "00:13 09/27/38"); | ||||
|         Assert.IsTrue(dateTime == logistics.DateTimeFromSequence); | ||||
|     } | ||||
|  | ||||
| } | ||||
| #endif | ||||
							
								
								
									
										29
									
								
								Adaptation/_Tests/Extract/Production/v2.58.0/CDE5-EQPT.cs
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										29
									
								
								Adaptation/_Tests/Extract/Production/v2.58.0/CDE5-EQPT.cs
									
									
									
									
									
										Normal file
									
								
							| @ -0,0 +1,29 @@ | ||||
| #if v2_58_0 | ||||
| using Microsoft.VisualStudio.TestTools.UnitTesting; | ||||
|  | ||||
| namespace Adaptation._Tests.Extract.Production.v2_58_0; | ||||
|  | ||||
| [TestClass] | ||||
| public class CDE5_EQPT | ||||
| { | ||||
|  | ||||
| #pragma warning disable CA2254 | ||||
| #pragma warning disable IDE0060 | ||||
|  | ||||
|     private static CreateSelfDescription.Production.v2_58_0.CDE5_EQPT _CDE5_EQPT; | ||||
|  | ||||
|     [ClassInitialize] | ||||
|     public static void ClassInitialize(TestContext testContext) | ||||
|     { | ||||
|         CreateSelfDescription.Production.v2_58_0.CDE5_EQPT.ClassInitialize(testContext); | ||||
|         _CDE5_EQPT = CreateSelfDescription.Production.v2_58_0.CDE5_EQPT.EAFLoggingUnitTesting; | ||||
|     } | ||||
|  | ||||
| #if DEBUG | ||||
|     [Ignore] | ||||
| #endif | ||||
|     [TestMethod] | ||||
|     public void Production__v2_58_0__CDE5_EQPT__DownloadRsMFile() => _CDE5_EQPT.Production__v2_58_0__CDE5_EQPT__DownloadRsMFile(); | ||||
|  | ||||
| } | ||||
| #endif | ||||
							
								
								
									
										82
									
								
								Adaptation/_Tests/Extract/Production/v2.58.0/CDE5.cs
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										82
									
								
								Adaptation/_Tests/Extract/Production/v2.58.0/CDE5.cs
									
									
									
									
									
										Normal file
									
								
							| @ -0,0 +1,82 @@ | ||||
| #if v2_58_0 | ||||
| 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_58_0; | ||||
|  | ||||
| [TestClass] | ||||
| public class CDE5 | ||||
| { | ||||
|  | ||||
| #pragma warning disable CA2254 | ||||
| #pragma warning disable IDE0060 | ||||
|  | ||||
|     private static CreateSelfDescription.Production.v2_58_0.CDE5 _CDE5; | ||||
|  | ||||
|     [ClassInitialize] | ||||
|     public static void ClassInitialize(TestContext testContext) | ||||
|     { | ||||
|         CreateSelfDescription.Production.v2_58_0.CDE5.ClassInitialize(testContext); | ||||
|         _CDE5 = CreateSelfDescription.Production.v2_58_0.CDE5.EAFLoggingUnitTesting; | ||||
|     } | ||||
|  | ||||
|     private static void NonThrowTryCatch() | ||||
|     { | ||||
|         try | ||||
|         { throw new Exception(); } | ||||
|         catch (Exception) { } | ||||
|     } | ||||
|  | ||||
| #if DEBUG | ||||
|     [Ignore] | ||||
| #endif | ||||
|     [TestMethod] | ||||
|     public void Production__v2_58_0__CDE5__RsM() => _CDE5.Production__v2_58_0__CDE5__RsM(); | ||||
|  | ||||
| #if DEBUG | ||||
|     [Ignore] | ||||
| #endif | ||||
|     [TestMethod] | ||||
|     public void Production__v2_58_0__CDE5__RsM637952212190000000__Normal() | ||||
|     { | ||||
|         DateTime dateTime; | ||||
|         string check = "*.RsM"; | ||||
|         bool validatePDSF = false; | ||||
|         _CDE5.Production__v2_58_0__CDE5__RsM(); | ||||
|         MethodBase methodBase = new StackFrame().GetMethod(); | ||||
|         Assert.IsFalse(string.IsNullOrEmpty(_CDE5.AdaptationTesting.TestContext.FullyQualifiedTestClassName)); | ||||
|         string[] variables = _CDE5.AdaptationTesting.GetVariables(methodBase, check, validatePDSF); | ||||
|         IFileRead fileRead = _CDE5.AdaptationTesting.Get(methodBase, sourceFileLocation: variables[2], sourceFileFilter: variables[3], useCyclicalForDescription: false); | ||||
|         Logistics logistics = new(fileRead); | ||||
|         _ = Shared.AdaptationTesting.ReExtractCompareUpdatePassDirectory(variables, fileRead, logistics, validatePDSF); | ||||
|         dateTime = FileHandlers.RsM.ProcessData.GetDateTime(logistics, string.Empty); | ||||
|         Assert.IsTrue(dateTime == logistics.DateTimeFromSequence); | ||||
|         dateTime = FileHandlers.RsM.ProcessData.GetDateTime(logistics, "00:13 09/27/38"); | ||||
|         Assert.IsTrue(dateTime == logistics.DateTimeFromSequence); | ||||
|         NonThrowTryCatch(); | ||||
|     } | ||||
|  | ||||
| #if DEBUG | ||||
|     [Ignore] | ||||
| #endif | ||||
|     [TestMethod] | ||||
|     public void Production__v2_58_0__CDE5__RsM638181148290431160__WMO() | ||||
|     { | ||||
|         string check = "*.RsM"; | ||||
|         bool validatePDSF = false; | ||||
|         _CDE5.Production__v2_58_0__CDE5__RsM(); | ||||
|         MethodBase methodBase = new StackFrame().GetMethod(); | ||||
|         Assert.IsFalse(string.IsNullOrEmpty(_CDE5.AdaptationTesting.TestContext.FullyQualifiedTestClassName)); | ||||
|         string[] variables = _CDE5.AdaptationTesting.GetVariables(methodBase, check, validatePDSF); | ||||
|         IFileRead fileRead = _CDE5.AdaptationTesting.Get(methodBase, sourceFileLocation: variables[2], sourceFileFilter: variables[3], useCyclicalForDescription: false); | ||||
|         Logistics logistics = new(fileRead); | ||||
|         _ = Shared.AdaptationTesting.ReExtractCompareUpdatePassDirectory(variables, fileRead, logistics, validatePDSF); | ||||
|         NonThrowTryCatch(); | ||||
|     } | ||||
|  | ||||
| } | ||||
| #endif | ||||
							
								
								
									
										45
									
								
								Adaptation/_Tests/Extract/Production/v2.58.0/CDE6-EQPT.cs
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										45
									
								
								Adaptation/_Tests/Extract/Production/v2.58.0/CDE6-EQPT.cs
									
									
									
									
									
										Normal file
									
								
							| @ -0,0 +1,45 @@ | ||||
| #if v2_58_0 | ||||
| using Microsoft.VisualStudio.TestTools.UnitTesting; | ||||
| using System.Diagnostics; | ||||
| using System.Reflection; | ||||
| using System.Threading; | ||||
|  | ||||
| namespace Adaptation._Tests.Extract.Production.v2_58_0; | ||||
|  | ||||
| [TestClass] | ||||
| public class CDE6_EQPT | ||||
| { | ||||
|  | ||||
| #pragma warning disable CA2254 | ||||
| #pragma warning disable IDE0060 | ||||
|  | ||||
|     private static CreateSelfDescription.Production.v2_58_0.CDE6_EQPT _CDE6_EQPT; | ||||
|  | ||||
|     [ClassInitialize] | ||||
|     public static void ClassInitialize(TestContext testContext) | ||||
|     { | ||||
|         CreateSelfDescription.Production.v2_58_0.CDE6_EQPT.ClassInitialize(testContext); | ||||
|         _CDE6_EQPT = CreateSelfDescription.Production.v2_58_0.CDE6_EQPT.EAFLoggingUnitTesting; | ||||
|     } | ||||
|  | ||||
| #if DEBUG | ||||
|     [Ignore] | ||||
| #endif | ||||
|     [TestMethod] | ||||
|     public void Production__v2_58_0__CDE6_EQPT__DownloadRsMFile() => _CDE6_EQPT.Production__v2_58_0__CDE6_EQPT__DownloadRsMFile(); | ||||
|  | ||||
|     [Ignore] | ||||
|     [TestMethod] | ||||
|     public void Production__v2_58_0__CDE6_EQPT__DownloadRsMFile638065099250000000__Normal() | ||||
|     { | ||||
|         bool validatePDSF = false; | ||||
|         string check = "CDE_Logs|WaferMeasurementData.log|.RsM"; | ||||
|         MethodBase methodBase = new StackFrame().GetMethod(); | ||||
|         _CDE6_EQPT.Production__v2_58_0__CDE6_EQPT__DownloadRsMFile(); | ||||
|         _ = _CDE6_EQPT.AdaptationTesting.GetVariables(methodBase, check, validatePDSF); | ||||
|         for (int i = 0; i < int.MaxValue; i++) | ||||
|             Thread.Sleep(500); | ||||
|     } | ||||
|  | ||||
| } | ||||
| #endif | ||||
							
								
								
									
										56
									
								
								Adaptation/_Tests/Extract/Production/v2.58.0/CDE6.cs
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										56
									
								
								Adaptation/_Tests/Extract/Production/v2.58.0/CDE6.cs
									
									
									
									
									
										Normal file
									
								
							| @ -0,0 +1,56 @@ | ||||
| #if v2_58_0 | ||||
| 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_58_0; | ||||
|  | ||||
| [TestClass] | ||||
| public class CDE6 | ||||
| { | ||||
|  | ||||
| #pragma warning disable CA2254 | ||||
| #pragma warning disable IDE0060 | ||||
|  | ||||
|     private static CreateSelfDescription.Production.v2_58_0.CDE6 _CDE6; | ||||
|  | ||||
|     [ClassInitialize] | ||||
|     public static void ClassInitialize(TestContext testContext) | ||||
|     { | ||||
|         CreateSelfDescription.Production.v2_58_0.CDE6.ClassInitialize(testContext); | ||||
|         _CDE6 = CreateSelfDescription.Production.v2_58_0.CDE6.EAFLoggingUnitTesting; | ||||
|     } | ||||
|  | ||||
| #if DEBUG | ||||
|     [Ignore] | ||||
| #endif | ||||
|     [TestMethod] | ||||
|     public void Production__v2_58_0__CDE6__RsM() => _CDE6.Production__v2_58_0__CDE6__RsM(); | ||||
|  | ||||
| #if DEBUG | ||||
|     [Ignore] | ||||
| #endif | ||||
|     [TestMethod] | ||||
|     public void Production__v2_58_0__CDE6__RsM638065099250000000__Normal() | ||||
|     { | ||||
|         DateTime dateTime; | ||||
|         string check = "*.RsM"; | ||||
|         bool validatePDSF = false; | ||||
|         _CDE6.Production__v2_58_0__CDE6__RsM(); | ||||
|         MethodBase methodBase = new StackFrame().GetMethod(); | ||||
|         Assert.IsFalse(string.IsNullOrEmpty(_CDE6.AdaptationTesting.TestContext.FullyQualifiedTestClassName)); | ||||
|         string[] variables = _CDE6.AdaptationTesting.GetVariables(methodBase, check, validatePDSF); | ||||
|         IFileRead fileRead = _CDE6.AdaptationTesting.Get(methodBase, sourceFileLocation: variables[2], sourceFileFilter: variables[3], useCyclicalForDescription: false); | ||||
|         Logistics logistics = new(fileRead); | ||||
|         _ = Shared.AdaptationTesting.ReExtractCompareUpdatePassDirectory(variables, fileRead, logistics, validatePDSF); | ||||
|         dateTime = FileHandlers.RsM.ProcessData.GetDateTime(logistics, string.Empty); | ||||
|         Assert.IsTrue(dateTime == logistics.DateTimeFromSequence); | ||||
|         dateTime = FileHandlers.RsM.ProcessData.GetDateTime(logistics, "00:13 09/27/38"); | ||||
|         Assert.IsTrue(dateTime == logistics.DateTimeFromSequence); | ||||
|     } | ||||
|  | ||||
| } | ||||
| #endif | ||||
							
								
								
									
										179
									
								
								Adaptation/_Tests/Extract/Production/v2.58.0/MET08RESIMAPCDE.cs
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										179
									
								
								Adaptation/_Tests/Extract/Production/v2.58.0/MET08RESIMAPCDE.cs
									
									
									
									
									
										Normal file
									
								
							| @ -0,0 +1,179 @@ | ||||
| #if v2_58_0 | ||||
| using Adaptation._Tests.Shared; | ||||
| 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_58_0; | ||||
|  | ||||
| [TestClass] | ||||
| public class MET08RESIMAPCDE | ||||
| { | ||||
|  | ||||
| #pragma warning disable CA2254 | ||||
| #pragma warning disable IDE0060 | ||||
|  | ||||
|     private static CreateSelfDescription.Production.v2_58_0.MET08RESIMAPCDE _MET08RESIMAPCDE; | ||||
|  | ||||
|     [ClassInitialize] | ||||
|     public static void ClassInitialize(TestContext testContext) | ||||
|     { | ||||
|         CreateSelfDescription.Production.v2_58_0.MET08RESIMAPCDE.ClassInitialize(testContext); | ||||
|         _MET08RESIMAPCDE = CreateSelfDescription.Production.v2_58_0.MET08RESIMAPCDE.EAFLoggingUnitTesting; | ||||
|     } | ||||
|  | ||||
|     private static void NonThrowTryCatch() | ||||
|     { | ||||
|         try | ||||
|         { throw new Exception(); } | ||||
|         catch (Exception) { } | ||||
|     } | ||||
|  | ||||
| #if DEBUG | ||||
|     [Ignore] | ||||
| #endif | ||||
|     [TestMethod] | ||||
|     public void Production__v2_58_0__MET08RESIMAPCDE__MoveMatchingFiles() => _MET08RESIMAPCDE.Production__v2_58_0__MET08RESIMAPCDE__MoveMatchingFiles(); | ||||
|  | ||||
| #if DEBUG | ||||
|     [Ignore] | ||||
| #endif | ||||
|     [TestMethod] | ||||
|     public void Production__v2_58_0__MET08RESIMAPCDE__MoveMatchingFiles637953064190000000__Normal() | ||||
|     { | ||||
|         DateTime dateTime; | ||||
|         string check = "*"; | ||||
|         bool validatePDSF = false; | ||||
|         _MET08RESIMAPCDE.Production__v2_58_0__MET08RESIMAPCDE__MoveMatchingFiles(); | ||||
|         MethodBase methodBase = new StackFrame().GetMethod(); | ||||
|         Assert.IsFalse(string.IsNullOrEmpty(_MET08RESIMAPCDE.AdaptationTesting.TestContext.FullyQualifiedTestClassName)); | ||||
|         string[] variables = _MET08RESIMAPCDE.AdaptationTesting.GetVariables(methodBase, check, validatePDSF); | ||||
|         IFileRead fileRead = _MET08RESIMAPCDE.AdaptationTesting.Get(methodBase, sourceFileLocation: variables[2], sourceFileFilter: variables[3], useCyclicalForDescription: false); | ||||
|         Logistics logistics = new(fileRead); | ||||
|         _ = AdaptationTesting.ReExtractCompareUpdatePassDirectory(variables, fileRead, logistics, validatePDSF); | ||||
|         dateTime = FileHandlers.RsM.ProcessData.GetDateTime(logistics, string.Empty); | ||||
|         Assert.IsTrue(dateTime == logistics.DateTimeFromSequence); | ||||
|         dateTime = FileHandlers.RsM.ProcessData.GetDateTime(logistics, "00:13 09/27/38"); | ||||
|         Assert.IsTrue(dateTime == logistics.DateTimeFromSequence); | ||||
|     } | ||||
|  | ||||
| #if DEBUG | ||||
|     [Ignore] | ||||
| #endif | ||||
|     [TestMethod] | ||||
|     public void Production__v2_58_0__MET08RESIMAPCDE__OpenInsightMetrologyViewer() => _MET08RESIMAPCDE.Production__v2_58_0__MET08RESIMAPCDE__OpenInsightMetrologyViewer(); | ||||
|  | ||||
| #if DEBUG | ||||
|     [Ignore] | ||||
| #endif | ||||
|     [TestMethod] | ||||
|     public void Production__v2_58_0__MET08RESIMAPCDE__OpenInsightMetrologyViewer638127615724700306__NewColumn() | ||||
|     { | ||||
|         string check = "*.pdsf"; | ||||
|         MethodBase methodBase = new StackFrame().GetMethod(); | ||||
|         _MET08RESIMAPCDE.Production__v2_58_0__MET08RESIMAPCDE__OpenInsightMetrologyViewer(); | ||||
|         string[] variables = _MET08RESIMAPCDE.AdaptationTesting.GetVariables(methodBase, check, validatePDSF: false); | ||||
|         IFileRead fileRead = _MET08RESIMAPCDE.AdaptationTesting.Get(methodBase, sourceFileLocation: variables[2], sourceFileFilter: variables[3], useCyclicalForDescription: false); | ||||
|         Logistics logistics = new(fileRead); | ||||
|         _ = AdaptationTesting.ReExtractCompareUpdatePassDirectory(variables, fileRead, logistics); | ||||
|     } | ||||
|  | ||||
| #if DEBUG | ||||
|     [Ignore] | ||||
| #endif | ||||
|     [TestMethod] | ||||
|     public void Production__v2_58_0__MET08RESIMAPCDE__IQSSi() => _MET08RESIMAPCDE.Production__v2_58_0__MET08RESIMAPCDE__IQSSi(); | ||||
|  | ||||
| #if DEBUG | ||||
|     [Ignore] | ||||
| #endif | ||||
|     [TestMethod] | ||||
|     public void Production__v2_58_0__MET08RESIMAPCDE__OpenInsight() => _MET08RESIMAPCDE.Production__v2_58_0__MET08RESIMAPCDE__OpenInsight(); | ||||
|  | ||||
| #if DEBUG | ||||
|     [Ignore] | ||||
| #endif | ||||
|     [TestMethod] | ||||
|     public void Production__v2_58_0__MET08RESIMAPCDE__OpenInsight638054501710000000__IqsSql() | ||||
|     { | ||||
|         string check = "*.pdsf"; | ||||
|         MethodBase methodBase = new StackFrame().GetMethod(); | ||||
|         _MET08RESIMAPCDE.Production__v2_58_0__MET08RESIMAPCDE__OpenInsight(); | ||||
|         string[] variables = _MET08RESIMAPCDE.AdaptationTesting.GetVariables(methodBase, check, validatePDSF: false); | ||||
|         IFileRead fileRead = _MET08RESIMAPCDE.AdaptationTesting.Get(methodBase, sourceFileLocation: variables[2], sourceFileFilter: variables[3], useCyclicalForDescription: false); | ||||
|         Logistics logistics = new(fileRead); | ||||
|         _ = AdaptationTesting.ReExtractCompareUpdatePassDirectory(variables, fileRead, logistics); | ||||
|     } | ||||
|  | ||||
| #if DEBUG | ||||
|     [Ignore] | ||||
| #endif | ||||
|     [TestMethod] | ||||
|     public void Production__v2_58_0__MET08RESIMAPCDE__OpenInsight638116271690000000__IqsSql() | ||||
|     { | ||||
|         string check = "*.pdsf"; | ||||
|         MethodBase methodBase = new StackFrame().GetMethod(); | ||||
|         _MET08RESIMAPCDE.Production__v2_58_0__MET08RESIMAPCDE__OpenInsight(); | ||||
|         string[] variables = _MET08RESIMAPCDE.AdaptationTesting.GetVariables(methodBase, check, validatePDSF: false); | ||||
|         IFileRead fileRead = _MET08RESIMAPCDE.AdaptationTesting.Get(methodBase, sourceFileLocation: variables[2], sourceFileFilter: variables[3], useCyclicalForDescription: false); | ||||
|         Logistics logistics = new(fileRead); | ||||
|         _ = AdaptationTesting.ReExtractCompareUpdatePassDirectory(variables, fileRead, logistics); | ||||
|     } | ||||
|  | ||||
| #if DEBUG | ||||
|     [Ignore] | ||||
| #endif | ||||
|     [TestMethod] | ||||
|     public void Production__v2_58_0__MET08RESIMAPCDE__OpenInsight638159693274771954__IqsSqlButSplit() | ||||
|     { | ||||
|         string check = "*.pdsf"; | ||||
|         MethodBase methodBase = new StackFrame().GetMethod(); | ||||
|         _MET08RESIMAPCDE.Production__v2_58_0__MET08RESIMAPCDE__OpenInsight(); | ||||
|         string[] variables = _MET08RESIMAPCDE.AdaptationTesting.GetVariables(methodBase, check, validatePDSF: false); | ||||
|         IFileRead fileRead = _MET08RESIMAPCDE.AdaptationTesting.Get(methodBase, sourceFileLocation: variables[2], sourceFileFilter: variables[3], useCyclicalForDescription: false); | ||||
|         Logistics logistics = new(fileRead); | ||||
|         _ = AdaptationTesting.ReExtractCompareUpdatePassDirectory(variables, fileRead, logistics); | ||||
|         NonThrowTryCatch(); | ||||
|     } | ||||
|  | ||||
| #if DEBUG | ||||
|     [Ignore] | ||||
| #endif | ||||
|     [TestMethod] | ||||
|     public void Production__v2_58_0__MET08RESIMAPCDE__OpenInsightMetrologyViewerAttachments() => _MET08RESIMAPCDE.Production__v2_58_0__MET08RESIMAPCDE__OpenInsightMetrologyViewerAttachments(); | ||||
|  | ||||
| #if DEBUG | ||||
|     [Ignore] | ||||
| #endif | ||||
|     [TestMethod] | ||||
|     public void Production__v2_58_0__MET08RESIMAPCDE__APC() => _MET08RESIMAPCDE.Production__v2_58_0__MET08RESIMAPCDE__APC(); | ||||
|  | ||||
| #if DEBUG | ||||
|     [Ignore] | ||||
| #endif | ||||
|     [TestMethod] | ||||
|     public void Production__v2_58_0__MET08RESIMAPCDE__SPaCe() => _MET08RESIMAPCDE.Production__v2_58_0__MET08RESIMAPCDE__SPaCe(); | ||||
|  | ||||
| #if DEBUG | ||||
|     [Ignore] | ||||
| #endif | ||||
|     [TestMethod] | ||||
|     public void Production__v2_58_0__MET08RESIMAPCDE__Processed() => _MET08RESIMAPCDE.Production__v2_58_0__MET08RESIMAPCDE__Processed(); | ||||
|  | ||||
| #if DEBUG | ||||
|     [Ignore] | ||||
| #endif | ||||
|     [TestMethod] | ||||
|     public void Production__v2_58_0__MET08RESIMAPCDE__Archive() => _MET08RESIMAPCDE.Production__v2_58_0__MET08RESIMAPCDE__Archive(); | ||||
|  | ||||
| #if DEBUG | ||||
|     [Ignore] | ||||
| #endif | ||||
|     [TestMethod] | ||||
|     public void Production__v2_58_0__MET08RESIMAPCDE__Dummy() => _MET08RESIMAPCDE.Production__v2_58_0__MET08RESIMAPCDE__Dummy(); | ||||
|  | ||||
| } | ||||
| #endif | ||||
							
								
								
									
										54
									
								
								Adaptation/_Tests/Extract/Production/v2.59.0/CDE4.cs
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										54
									
								
								Adaptation/_Tests/Extract/Production/v2.59.0/CDE4.cs
									
									
									
									
									
										Normal file
									
								
							| @ -0,0 +1,54 @@ | ||||
| #if v2_59_0 | ||||
| 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_59_0; | ||||
|  | ||||
| [TestClass] | ||||
| public class CDE4 | ||||
| { | ||||
|  | ||||
| #pragma warning disable CA2254 | ||||
| #pragma warning disable IDE0060 | ||||
|  | ||||
|     private static CreateSelfDescription.Production.v2_59_0.CDE4 _CDE4; | ||||
|  | ||||
|     [ClassInitialize] | ||||
|     public static void ClassInitialize(TestContext testContext) | ||||
|     { | ||||
|         CreateSelfDescription.Production.v2_59_0.CDE4.ClassInitialize(testContext); | ||||
|         _CDE4 = CreateSelfDescription.Production.v2_59_0.CDE4.EAFLoggingUnitTesting; | ||||
|     } | ||||
|  | ||||
| #if DEBUG | ||||
|     [Ignore] | ||||
| #endif | ||||
|     [TestMethod] | ||||
|     public void Production__v2_59_0__CDE4__RsM() => _CDE4.Production__v2_59_0__CDE4__RsM(); | ||||
|  | ||||
| #if DEBUG | ||||
|     [Ignore] | ||||
| #endif | ||||
|     [TestMethod] | ||||
|     public void Production__v2_59_0__CDE4__RsM637919422210000000__Normal() | ||||
|     { | ||||
|         DateTime dateTime; | ||||
|         string check = "*.RsM"; | ||||
|         _CDE4.Production__v2_59_0__CDE4__RsM(); | ||||
|         MethodBase methodBase = new StackFrame().GetMethod(); | ||||
|         string[] variables = _CDE4.AdaptationTesting.GetVariables(methodBase, check, validatePDSF: false); | ||||
|         IFileRead fileRead = _CDE4.AdaptationTesting.Get(methodBase, sourceFileLocation: variables[2], sourceFileFilter: variables[3], useCyclicalForDescription: false); | ||||
|         Logistics logistics = new(fileRead); | ||||
|         _ = Shared.AdaptationTesting.ReExtractCompareUpdatePassDirectory(variables, fileRead, logistics, validatePDSF: false); | ||||
|         dateTime = FileHandlers.RsM.ProcessData.GetDateTime(logistics, string.Empty); | ||||
|         Assert.AreEqual(logistics.DateTimeFromSequence, dateTime); | ||||
|         dateTime = FileHandlers.RsM.ProcessData.GetDateTime(logistics, "00:13 09/27/38"); | ||||
|         Assert.AreEqual(logistics.DateTimeFromSequence, dateTime); | ||||
|     } | ||||
|  | ||||
| } | ||||
| #endif | ||||
							
								
								
									
										29
									
								
								Adaptation/_Tests/Extract/Production/v2.59.0/CDE5-EQPT.cs
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										29
									
								
								Adaptation/_Tests/Extract/Production/v2.59.0/CDE5-EQPT.cs
									
									
									
									
									
										Normal file
									
								
							| @ -0,0 +1,29 @@ | ||||
| #if v2_59_0 | ||||
| using Microsoft.VisualStudio.TestTools.UnitTesting; | ||||
|  | ||||
| namespace Adaptation._Tests.Extract.Production.v2_59_0; | ||||
|  | ||||
| [TestClass] | ||||
| public class CDE5_EQPT | ||||
| { | ||||
|  | ||||
| #pragma warning disable CA2254 | ||||
| #pragma warning disable IDE0060 | ||||
|  | ||||
|     private static CreateSelfDescription.Production.v2_59_0.CDE5_EQPT _CDE5_EQPT; | ||||
|  | ||||
|     [ClassInitialize] | ||||
|     public static void ClassInitialize(TestContext testContext) | ||||
|     { | ||||
|         CreateSelfDescription.Production.v2_59_0.CDE5_EQPT.ClassInitialize(testContext); | ||||
|         _CDE5_EQPT = CreateSelfDescription.Production.v2_59_0.CDE5_EQPT.EAFLoggingUnitTesting; | ||||
|     } | ||||
|  | ||||
| #if DEBUG | ||||
|     [Ignore] | ||||
| #endif | ||||
|     [TestMethod] | ||||
|     public void Production__v2_59_0__CDE5_EQPT__DownloadRsMFile() => _CDE5_EQPT.Production__v2_59_0__CDE5_EQPT__DownloadRsMFile(); | ||||
|  | ||||
| } | ||||
| #endif | ||||
							
								
								
									
										82
									
								
								Adaptation/_Tests/Extract/Production/v2.59.0/CDE5.cs
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										82
									
								
								Adaptation/_Tests/Extract/Production/v2.59.0/CDE5.cs
									
									
									
									
									
										Normal file
									
								
							| @ -0,0 +1,82 @@ | ||||
| #if v2_59_0 | ||||
| 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_59_0; | ||||
|  | ||||
| [TestClass] | ||||
| public class CDE5 | ||||
| { | ||||
|  | ||||
| #pragma warning disable CA2254 | ||||
| #pragma warning disable IDE0060 | ||||
|  | ||||
|     private static CreateSelfDescription.Production.v2_59_0.CDE5 _CDE5; | ||||
|  | ||||
|     [ClassInitialize] | ||||
|     public static void ClassInitialize(TestContext testContext) | ||||
|     { | ||||
|         CreateSelfDescription.Production.v2_59_0.CDE5.ClassInitialize(testContext); | ||||
|         _CDE5 = CreateSelfDescription.Production.v2_59_0.CDE5.EAFLoggingUnitTesting; | ||||
|     } | ||||
|  | ||||
|     private static void NonThrowTryCatch() | ||||
|     { | ||||
|         try | ||||
|         { throw new Exception(); } | ||||
|         catch (Exception) { } | ||||
|     } | ||||
|  | ||||
| #if DEBUG | ||||
|     [Ignore] | ||||
| #endif | ||||
|     [TestMethod] | ||||
|     public void Production__v2_59_0__CDE5__RsM() => _CDE5.Production__v2_59_0__CDE5__RsM(); | ||||
|  | ||||
| #if DEBUG | ||||
|     [Ignore] | ||||
| #endif | ||||
|     [TestMethod] | ||||
|     public void Production__v2_59_0__CDE5__RsM637952212190000000__Normal() | ||||
|     { | ||||
|         DateTime dateTime; | ||||
|         string check = "*.RsM"; | ||||
|         bool validatePDSF = false; | ||||
|         _CDE5.Production__v2_59_0__CDE5__RsM(); | ||||
|         MethodBase methodBase = new StackFrame().GetMethod(); | ||||
|         Assert.IsFalse(string.IsNullOrEmpty(_CDE5.AdaptationTesting.TestContext.FullyQualifiedTestClassName)); | ||||
|         string[] variables = _CDE5.AdaptationTesting.GetVariables(methodBase, check, validatePDSF); | ||||
|         IFileRead fileRead = _CDE5.AdaptationTesting.Get(methodBase, sourceFileLocation: variables[2], sourceFileFilter: variables[3], useCyclicalForDescription: false); | ||||
|         Logistics logistics = new(fileRead); | ||||
|         _ = Shared.AdaptationTesting.ReExtractCompareUpdatePassDirectory(variables, fileRead, logistics, validatePDSF); | ||||
|         dateTime = FileHandlers.RsM.ProcessData.GetDateTime(logistics, string.Empty); | ||||
|         Assert.AreEqual(logistics.DateTimeFromSequence, dateTime); | ||||
|         dateTime = FileHandlers.RsM.ProcessData.GetDateTime(logistics, "00:13 09/27/38"); | ||||
|         Assert.AreEqual(logistics.DateTimeFromSequence, dateTime); | ||||
|         NonThrowTryCatch(); | ||||
|     } | ||||
|  | ||||
| #if DEBUG | ||||
|     [Ignore] | ||||
| #endif | ||||
|     [TestMethod] | ||||
|     public void Production__v2_59_0__CDE5__RsM638181148290431160__WMO() | ||||
|     { | ||||
|         string check = "*.RsM"; | ||||
|         bool validatePDSF = false; | ||||
|         _CDE5.Production__v2_59_0__CDE5__RsM(); | ||||
|         MethodBase methodBase = new StackFrame().GetMethod(); | ||||
|         Assert.IsFalse(string.IsNullOrEmpty(_CDE5.AdaptationTesting.TestContext.FullyQualifiedTestClassName)); | ||||
|         string[] variables = _CDE5.AdaptationTesting.GetVariables(methodBase, check, validatePDSF); | ||||
|         IFileRead fileRead = _CDE5.AdaptationTesting.Get(methodBase, sourceFileLocation: variables[2], sourceFileFilter: variables[3], useCyclicalForDescription: false); | ||||
|         Logistics logistics = new(fileRead); | ||||
|         _ = Shared.AdaptationTesting.ReExtractCompareUpdatePassDirectory(variables, fileRead, logistics, validatePDSF); | ||||
|         NonThrowTryCatch(); | ||||
|     } | ||||
|  | ||||
| } | ||||
| #endif | ||||
							
								
								
									
										45
									
								
								Adaptation/_Tests/Extract/Production/v2.59.0/CDE6-EQPT.cs
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										45
									
								
								Adaptation/_Tests/Extract/Production/v2.59.0/CDE6-EQPT.cs
									
									
									
									
									
										Normal file
									
								
							| @ -0,0 +1,45 @@ | ||||
| #if v2_59_0 | ||||
| using Microsoft.VisualStudio.TestTools.UnitTesting; | ||||
| using System.Diagnostics; | ||||
| using System.Reflection; | ||||
| using System.Threading; | ||||
|  | ||||
| namespace Adaptation._Tests.Extract.Production.v2_59_0; | ||||
|  | ||||
| [TestClass] | ||||
| public class CDE6_EQPT | ||||
| { | ||||
|  | ||||
| #pragma warning disable CA2254 | ||||
| #pragma warning disable IDE0060 | ||||
|  | ||||
|     private static CreateSelfDescription.Production.v2_59_0.CDE6_EQPT _CDE6_EQPT; | ||||
|  | ||||
|     [ClassInitialize] | ||||
|     public static void ClassInitialize(TestContext testContext) | ||||
|     { | ||||
|         CreateSelfDescription.Production.v2_59_0.CDE6_EQPT.ClassInitialize(testContext); | ||||
|         _CDE6_EQPT = CreateSelfDescription.Production.v2_59_0.CDE6_EQPT.EAFLoggingUnitTesting; | ||||
|     } | ||||
|  | ||||
| #if DEBUG | ||||
|     [Ignore] | ||||
| #endif | ||||
|     [TestMethod] | ||||
|     public void Production__v2_59_0__CDE6_EQPT__DownloadRsMFile() => _CDE6_EQPT.Production__v2_59_0__CDE6_EQPT__DownloadRsMFile(); | ||||
|  | ||||
|     [Ignore] | ||||
|     [TestMethod] | ||||
|     public void Production__v2_59_0__CDE6_EQPT__DownloadRsMFile638065099250000000__Normal() | ||||
|     { | ||||
|         bool validatePDSF = false; | ||||
|         string check = "CDE_Logs|WaferMeasurementData.log|.RsM"; | ||||
|         MethodBase methodBase = new StackFrame().GetMethod(); | ||||
|         _CDE6_EQPT.Production__v2_59_0__CDE6_EQPT__DownloadRsMFile(); | ||||
|         _ = _CDE6_EQPT.AdaptationTesting.GetVariables(methodBase, check, validatePDSF); | ||||
|         for (int i = 0; i < int.MaxValue; i++) | ||||
|             Thread.Sleep(500); | ||||
|     } | ||||
|  | ||||
| } | ||||
| #endif | ||||
							
								
								
									
										56
									
								
								Adaptation/_Tests/Extract/Production/v2.59.0/CDE6.cs
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										56
									
								
								Adaptation/_Tests/Extract/Production/v2.59.0/CDE6.cs
									
									
									
									
									
										Normal file
									
								
							| @ -0,0 +1,56 @@ | ||||
| #if v2_59_0 | ||||
| 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_59_0; | ||||
|  | ||||
| [TestClass] | ||||
| public class CDE6 | ||||
| { | ||||
|  | ||||
| #pragma warning disable CA2254 | ||||
| #pragma warning disable IDE0060 | ||||
|  | ||||
|     private static CreateSelfDescription.Production.v2_59_0.CDE6 _CDE6; | ||||
|  | ||||
|     [ClassInitialize] | ||||
|     public static void ClassInitialize(TestContext testContext) | ||||
|     { | ||||
|         CreateSelfDescription.Production.v2_59_0.CDE6.ClassInitialize(testContext); | ||||
|         _CDE6 = CreateSelfDescription.Production.v2_59_0.CDE6.EAFLoggingUnitTesting; | ||||
|     } | ||||
|  | ||||
| #if DEBUG | ||||
|     [Ignore] | ||||
| #endif | ||||
|     [TestMethod] | ||||
|     public void Production__v2_59_0__CDE6__RsM() => _CDE6.Production__v2_59_0__CDE6__RsM(); | ||||
|  | ||||
| #if DEBUG | ||||
|     [Ignore] | ||||
| #endif | ||||
|     [TestMethod] | ||||
|     public void Production__v2_59_0__CDE6__RsM638065099250000000__Normal() | ||||
|     { | ||||
|         DateTime dateTime; | ||||
|         string check = "*.RsM"; | ||||
|         bool validatePDSF = false; | ||||
|         _CDE6.Production__v2_59_0__CDE6__RsM(); | ||||
|         MethodBase methodBase = new StackFrame().GetMethod(); | ||||
|         Assert.IsFalse(string.IsNullOrEmpty(_CDE6.AdaptationTesting.TestContext.FullyQualifiedTestClassName)); | ||||
|         string[] variables = _CDE6.AdaptationTesting.GetVariables(methodBase, check, validatePDSF); | ||||
|         IFileRead fileRead = _CDE6.AdaptationTesting.Get(methodBase, sourceFileLocation: variables[2], sourceFileFilter: variables[3], useCyclicalForDescription: false); | ||||
|         Logistics logistics = new(fileRead); | ||||
|         _ = Shared.AdaptationTesting.ReExtractCompareUpdatePassDirectory(variables, fileRead, logistics, validatePDSF); | ||||
|         dateTime = FileHandlers.RsM.ProcessData.GetDateTime(logistics, string.Empty); | ||||
|         Assert.AreEqual(logistics.DateTimeFromSequence, dateTime); | ||||
|         dateTime = FileHandlers.RsM.ProcessData.GetDateTime(logistics, "00:13 09/27/38"); | ||||
|         Assert.AreEqual(logistics.DateTimeFromSequence, dateTime); | ||||
|     } | ||||
|  | ||||
| } | ||||
| #endif | ||||
							
								
								
									
										179
									
								
								Adaptation/_Tests/Extract/Production/v2.59.0/MET08RESIMAPCDE.cs
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										179
									
								
								Adaptation/_Tests/Extract/Production/v2.59.0/MET08RESIMAPCDE.cs
									
									
									
									
									
										Normal file
									
								
							| @ -0,0 +1,179 @@ | ||||
| #if v2_59_0 | ||||
| using Adaptation._Tests.Shared; | ||||
| 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_59_0; | ||||
|  | ||||
| [TestClass] | ||||
| public class MET08RESIMAPCDE | ||||
| { | ||||
|  | ||||
| #pragma warning disable CA2254 | ||||
| #pragma warning disable IDE0060 | ||||
|  | ||||
|     private static CreateSelfDescription.Production.v2_59_0.MET08RESIMAPCDE _MET08RESIMAPCDE; | ||||
|  | ||||
|     [ClassInitialize] | ||||
|     public static void ClassInitialize(TestContext testContext) | ||||
|     { | ||||
|         CreateSelfDescription.Production.v2_59_0.MET08RESIMAPCDE.ClassInitialize(testContext); | ||||
|         _MET08RESIMAPCDE = CreateSelfDescription.Production.v2_59_0.MET08RESIMAPCDE.EAFLoggingUnitTesting; | ||||
|     } | ||||
|  | ||||
|     private static void NonThrowTryCatch() | ||||
|     { | ||||
|         try | ||||
|         { throw new Exception(); } | ||||
|         catch (Exception) { } | ||||
|     } | ||||
|  | ||||
| #if DEBUG | ||||
|     [Ignore] | ||||
| #endif | ||||
|     [TestMethod] | ||||
|     public void Production__v2_59_0__MET08RESIMAPCDE__MoveMatchingFiles() => _MET08RESIMAPCDE.Production__v2_59_0__MET08RESIMAPCDE__MoveMatchingFiles(); | ||||
|  | ||||
| #if DEBUG | ||||
|     [Ignore] | ||||
| #endif | ||||
|     [TestMethod] | ||||
|     public void Production__v2_59_0__MET08RESIMAPCDE__MoveMatchingFiles637953064190000000__Normal() | ||||
|     { | ||||
|         DateTime dateTime; | ||||
|         string check = "*"; | ||||
|         bool validatePDSF = false; | ||||
|         _MET08RESIMAPCDE.Production__v2_59_0__MET08RESIMAPCDE__MoveMatchingFiles(); | ||||
|         MethodBase methodBase = new StackFrame().GetMethod(); | ||||
|         Assert.IsFalse(string.IsNullOrEmpty(_MET08RESIMAPCDE.AdaptationTesting.TestContext.FullyQualifiedTestClassName)); | ||||
|         string[] variables = _MET08RESIMAPCDE.AdaptationTesting.GetVariables(methodBase, check, validatePDSF); | ||||
|         IFileRead fileRead = _MET08RESIMAPCDE.AdaptationTesting.Get(methodBase, sourceFileLocation: variables[2], sourceFileFilter: variables[3], useCyclicalForDescription: false); | ||||
|         Logistics logistics = new(fileRead); | ||||
|         _ = AdaptationTesting.ReExtractCompareUpdatePassDirectory(variables, fileRead, logistics, validatePDSF); | ||||
|         dateTime = FileHandlers.RsM.ProcessData.GetDateTime(logistics, string.Empty); | ||||
|         Assert.AreEqual(logistics.DateTimeFromSequence, dateTime); | ||||
|         dateTime = FileHandlers.RsM.ProcessData.GetDateTime(logistics, "00:13 09/27/38"); | ||||
|         Assert.AreEqual(logistics.DateTimeFromSequence, dateTime); | ||||
|     } | ||||
|  | ||||
| #if DEBUG | ||||
|     [Ignore] | ||||
| #endif | ||||
|     [TestMethod] | ||||
|     public void Production__v2_59_0__MET08RESIMAPCDE__OpenInsightMetrologyViewer() => _MET08RESIMAPCDE.Production__v2_59_0__MET08RESIMAPCDE__OpenInsightMetrologyViewer(); | ||||
|  | ||||
| #if DEBUG | ||||
|     [Ignore] | ||||
| #endif | ||||
|     [TestMethod] | ||||
|     public void Production__v2_59_0__MET08RESIMAPCDE__OpenInsightMetrologyViewer638127615724700306__NewColumn() | ||||
|     { | ||||
|         string check = "*.pdsf"; | ||||
|         MethodBase methodBase = new StackFrame().GetMethod(); | ||||
|         _MET08RESIMAPCDE.Production__v2_59_0__MET08RESIMAPCDE__OpenInsightMetrologyViewer(); | ||||
|         string[] variables = _MET08RESIMAPCDE.AdaptationTesting.GetVariables(methodBase, check, validatePDSF: false); | ||||
|         IFileRead fileRead = _MET08RESIMAPCDE.AdaptationTesting.Get(methodBase, sourceFileLocation: variables[2], sourceFileFilter: variables[3], useCyclicalForDescription: false); | ||||
|         Logistics logistics = new(fileRead); | ||||
|         _ = AdaptationTesting.ReExtractCompareUpdatePassDirectory(variables, fileRead, logistics); | ||||
|     } | ||||
|  | ||||
| #if DEBUG | ||||
|     [Ignore] | ||||
| #endif | ||||
|     [TestMethod] | ||||
|     public void Production__v2_59_0__MET08RESIMAPCDE__IQSSi() => _MET08RESIMAPCDE.Production__v2_59_0__MET08RESIMAPCDE__IQSSi(); | ||||
|  | ||||
| #if DEBUG | ||||
|     [Ignore] | ||||
| #endif | ||||
|     [TestMethod] | ||||
|     public void Production__v2_59_0__MET08RESIMAPCDE__OpenInsight() => _MET08RESIMAPCDE.Production__v2_59_0__MET08RESIMAPCDE__OpenInsight(); | ||||
|  | ||||
| #if DEBUG | ||||
|     [Ignore] | ||||
| #endif | ||||
|     [TestMethod] | ||||
|     public void Production__v2_59_0__MET08RESIMAPCDE__OpenInsight638054501710000000__IqsSql() | ||||
|     { | ||||
|         string check = "*.pdsf"; | ||||
|         MethodBase methodBase = new StackFrame().GetMethod(); | ||||
|         _MET08RESIMAPCDE.Production__v2_59_0__MET08RESIMAPCDE__OpenInsight(); | ||||
|         string[] variables = _MET08RESIMAPCDE.AdaptationTesting.GetVariables(methodBase, check, validatePDSF: false); | ||||
|         IFileRead fileRead = _MET08RESIMAPCDE.AdaptationTesting.Get(methodBase, sourceFileLocation: variables[2], sourceFileFilter: variables[3], useCyclicalForDescription: false); | ||||
|         Logistics logistics = new(fileRead); | ||||
|         _ = AdaptationTesting.ReExtractCompareUpdatePassDirectory(variables, fileRead, logistics); | ||||
|     } | ||||
|  | ||||
| #if DEBUG | ||||
|     [Ignore] | ||||
| #endif | ||||
|     [TestMethod] | ||||
|     public void Production__v2_59_0__MET08RESIMAPCDE__OpenInsight638116271690000000__IqsSql() | ||||
|     { | ||||
|         string check = "*.pdsf"; | ||||
|         MethodBase methodBase = new StackFrame().GetMethod(); | ||||
|         _MET08RESIMAPCDE.Production__v2_59_0__MET08RESIMAPCDE__OpenInsight(); | ||||
|         string[] variables = _MET08RESIMAPCDE.AdaptationTesting.GetVariables(methodBase, check, validatePDSF: false); | ||||
|         IFileRead fileRead = _MET08RESIMAPCDE.AdaptationTesting.Get(methodBase, sourceFileLocation: variables[2], sourceFileFilter: variables[3], useCyclicalForDescription: false); | ||||
|         Logistics logistics = new(fileRead); | ||||
|         _ = AdaptationTesting.ReExtractCompareUpdatePassDirectory(variables, fileRead, logistics); | ||||
|     } | ||||
|  | ||||
| #if DEBUG | ||||
|     [Ignore] | ||||
| #endif | ||||
|     [TestMethod] | ||||
|     public void Production__v2_59_0__MET08RESIMAPCDE__OpenInsight638159693274771954__IqsSqlButSplit() | ||||
|     { | ||||
|         string check = "*.pdsf"; | ||||
|         MethodBase methodBase = new StackFrame().GetMethod(); | ||||
|         _MET08RESIMAPCDE.Production__v2_59_0__MET08RESIMAPCDE__OpenInsight(); | ||||
|         string[] variables = _MET08RESIMAPCDE.AdaptationTesting.GetVariables(methodBase, check, validatePDSF: false); | ||||
|         IFileRead fileRead = _MET08RESIMAPCDE.AdaptationTesting.Get(methodBase, sourceFileLocation: variables[2], sourceFileFilter: variables[3], useCyclicalForDescription: false); | ||||
|         Logistics logistics = new(fileRead); | ||||
|         _ = AdaptationTesting.ReExtractCompareUpdatePassDirectory(variables, fileRead, logistics); | ||||
|         NonThrowTryCatch(); | ||||
|     } | ||||
|  | ||||
| #if DEBUG | ||||
|     [Ignore] | ||||
| #endif | ||||
|     [TestMethod] | ||||
|     public void Production__v2_59_0__MET08RESIMAPCDE__OpenInsightMetrologyViewerAttachments() => _MET08RESIMAPCDE.Production__v2_59_0__MET08RESIMAPCDE__OpenInsightMetrologyViewerAttachments(); | ||||
|  | ||||
| #if DEBUG | ||||
|     [Ignore] | ||||
| #endif | ||||
|     [TestMethod] | ||||
|     public void Production__v2_59_0__MET08RESIMAPCDE__APC() => _MET08RESIMAPCDE.Production__v2_59_0__MET08RESIMAPCDE__APC(); | ||||
|  | ||||
| #if DEBUG | ||||
|     [Ignore] | ||||
| #endif | ||||
|     [TestMethod] | ||||
|     public void Production__v2_59_0__MET08RESIMAPCDE__SPaCe() => _MET08RESIMAPCDE.Production__v2_59_0__MET08RESIMAPCDE__SPaCe(); | ||||
|  | ||||
| #if DEBUG | ||||
|     [Ignore] | ||||
| #endif | ||||
|     [TestMethod] | ||||
|     public void Production__v2_59_0__MET08RESIMAPCDE__Processed() => _MET08RESIMAPCDE.Production__v2_59_0__MET08RESIMAPCDE__Processed(); | ||||
|  | ||||
| #if DEBUG | ||||
|     [Ignore] | ||||
| #endif | ||||
|     [TestMethod] | ||||
|     public void Production__v2_59_0__MET08RESIMAPCDE__Archive() => _MET08RESIMAPCDE.Production__v2_59_0__MET08RESIMAPCDE__Archive(); | ||||
|  | ||||
| #if DEBUG | ||||
|     [Ignore] | ||||
| #endif | ||||
|     [TestMethod] | ||||
|     public void Production__v2_59_0__MET08RESIMAPCDE__Dummy() => _MET08RESIMAPCDE.Production__v2_59_0__MET08RESIMAPCDE__Dummy(); | ||||
|  | ||||
| } | ||||
| #endif | ||||
							
								
								
									
										54
									
								
								Adaptation/_Tests/Extract/Production/v2.60.0/CDE4.cs
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										54
									
								
								Adaptation/_Tests/Extract/Production/v2.60.0/CDE4.cs
									
									
									
									
									
										Normal file
									
								
							| @ -0,0 +1,54 @@ | ||||
| #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 CDE4 | ||||
| { | ||||
|  | ||||
| #pragma warning disable CA2254 | ||||
| #pragma warning disable IDE0060 | ||||
|  | ||||
|     private static CreateSelfDescription.Production.v2_60_0.CDE4 _CDE4; | ||||
|  | ||||
|     [ClassInitialize] | ||||
|     public static void ClassInitialize(TestContext testContext) | ||||
|     { | ||||
|         CreateSelfDescription.Production.v2_60_0.CDE4.ClassInitialize(testContext); | ||||
|         _CDE4 = CreateSelfDescription.Production.v2_60_0.CDE4.EAFLoggingUnitTesting; | ||||
|     } | ||||
|  | ||||
| #if DEBUG | ||||
|     [Ignore] | ||||
| #endif | ||||
|     [TestMethod] | ||||
|     public void Production__v2_60_0__CDE4__RsM() => _CDE4.Production__v2_60_0__CDE4__RsM(); | ||||
|  | ||||
| #if DEBUG | ||||
|     [Ignore] | ||||
| #endif | ||||
|     [TestMethod] | ||||
|     public void Production__v2_60_0__CDE4__RsM637919422210000000__Normal() | ||||
|     { | ||||
|         DateTime dateTime; | ||||
|         string check = "*.RsM"; | ||||
|         _CDE4.Production__v2_60_0__CDE4__RsM(); | ||||
|         MethodBase methodBase = new StackFrame().GetMethod(); | ||||
|         string[] variables = _CDE4.AdaptationTesting.GetVariables(methodBase, check, validatePDSF: false); | ||||
|         IFileRead fileRead = _CDE4.AdaptationTesting.Get(methodBase, sourceFileLocation: variables[2], sourceFileFilter: variables[3], useCyclicalForDescription: false); | ||||
|         Logistics logistics = new(fileRead); | ||||
|         _ = Shared.AdaptationTesting.ReExtractCompareUpdatePassDirectory(variables, fileRead, logistics, validatePDSF: false); | ||||
|         dateTime = FileHandlers.RsM.ProcessData.GetDateTime(logistics, string.Empty); | ||||
|         Assert.AreEqual(logistics.DateTimeFromSequence, dateTime); | ||||
|         dateTime = FileHandlers.RsM.ProcessData.GetDateTime(logistics, "00:13 09/27/38"); | ||||
|         Assert.AreEqual(logistics.DateTimeFromSequence, dateTime); | ||||
|     } | ||||
|  | ||||
| } | ||||
| #endif | ||||
							
								
								
									
										29
									
								
								Adaptation/_Tests/Extract/Production/v2.60.0/CDE5-EQPT.cs
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										29
									
								
								Adaptation/_Tests/Extract/Production/v2.60.0/CDE5-EQPT.cs
									
									
									
									
									
										Normal file
									
								
							| @ -0,0 +1,29 @@ | ||||
| #if true | ||||
| using Microsoft.VisualStudio.TestTools.UnitTesting; | ||||
|  | ||||
| namespace Adaptation._Tests.Extract.Production.v2_60_0; | ||||
|  | ||||
| [TestClass] | ||||
| public class CDE5_EQPT | ||||
| { | ||||
|  | ||||
| #pragma warning disable CA2254 | ||||
| #pragma warning disable IDE0060 | ||||
|  | ||||
|     private static CreateSelfDescription.Production.v2_60_0.CDE5_EQPT _CDE5_EQPT; | ||||
|  | ||||
|     [ClassInitialize] | ||||
|     public static void ClassInitialize(TestContext testContext) | ||||
|     { | ||||
|         CreateSelfDescription.Production.v2_60_0.CDE5_EQPT.ClassInitialize(testContext); | ||||
|         _CDE5_EQPT = CreateSelfDescription.Production.v2_60_0.CDE5_EQPT.EAFLoggingUnitTesting; | ||||
|     } | ||||
|  | ||||
| #if DEBUG | ||||
|     [Ignore] | ||||
| #endif | ||||
|     [TestMethod] | ||||
|     public void Production__v2_60_0__CDE5_EQPT__DownloadRsMFile() => _CDE5_EQPT.Production__v2_60_0__CDE5_EQPT__DownloadRsMFile(); | ||||
|  | ||||
| } | ||||
| #endif | ||||
							
								
								
									
										82
									
								
								Adaptation/_Tests/Extract/Production/v2.60.0/CDE5.cs
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										82
									
								
								Adaptation/_Tests/Extract/Production/v2.60.0/CDE5.cs
									
									
									
									
									
										Normal file
									
								
							| @ -0,0 +1,82 @@ | ||||
| #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 CDE5 | ||||
| { | ||||
|  | ||||
| #pragma warning disable CA2254 | ||||
| #pragma warning disable IDE0060 | ||||
|  | ||||
|     private static CreateSelfDescription.Production.v2_60_0.CDE5 _CDE5; | ||||
|  | ||||
|     [ClassInitialize] | ||||
|     public static void ClassInitialize(TestContext testContext) | ||||
|     { | ||||
|         CreateSelfDescription.Production.v2_60_0.CDE5.ClassInitialize(testContext); | ||||
|         _CDE5 = CreateSelfDescription.Production.v2_60_0.CDE5.EAFLoggingUnitTesting; | ||||
|     } | ||||
|  | ||||
|     private static void NonThrowTryCatch() | ||||
|     { | ||||
|         try | ||||
|         { throw new Exception(); } | ||||
|         catch (Exception) { } | ||||
|     } | ||||
|  | ||||
| #if DEBUG | ||||
|     [Ignore] | ||||
| #endif | ||||
|     [TestMethod] | ||||
|     public void Production__v2_60_0__CDE5__RsM() => _CDE5.Production__v2_60_0__CDE5__RsM(); | ||||
|  | ||||
| #if DEBUG | ||||
|     [Ignore] | ||||
| #endif | ||||
|     [TestMethod] | ||||
|     public void Production__v2_60_0__CDE5__RsM637952212190000000__Normal() | ||||
|     { | ||||
|         DateTime dateTime; | ||||
|         string check = "*.RsM"; | ||||
|         bool validatePDSF = false; | ||||
|         _CDE5.Production__v2_60_0__CDE5__RsM(); | ||||
|         MethodBase methodBase = new StackFrame().GetMethod(); | ||||
|         Assert.IsFalse(string.IsNullOrEmpty(_CDE5.AdaptationTesting.TestContext.FullyQualifiedTestClassName)); | ||||
|         string[] variables = _CDE5.AdaptationTesting.GetVariables(methodBase, check, validatePDSF); | ||||
|         IFileRead fileRead = _CDE5.AdaptationTesting.Get(methodBase, sourceFileLocation: variables[2], sourceFileFilter: variables[3], useCyclicalForDescription: false); | ||||
|         Logistics logistics = new(fileRead); | ||||
|         _ = Shared.AdaptationTesting.ReExtractCompareUpdatePassDirectory(variables, fileRead, logistics, validatePDSF); | ||||
|         dateTime = FileHandlers.RsM.ProcessData.GetDateTime(logistics, string.Empty); | ||||
|         Assert.AreEqual(logistics.DateTimeFromSequence, dateTime); | ||||
|         dateTime = FileHandlers.RsM.ProcessData.GetDateTime(logistics, "00:13 09/27/38"); | ||||
|         Assert.AreEqual(logistics.DateTimeFromSequence, dateTime); | ||||
|         NonThrowTryCatch(); | ||||
|     } | ||||
|  | ||||
| #if DEBUG | ||||
|     [Ignore] | ||||
| #endif | ||||
|     [TestMethod] | ||||
|     public void Production__v2_60_0__CDE5__RsM638181148290431160__WMO() | ||||
|     { | ||||
|         string check = "*.RsM"; | ||||
|         bool validatePDSF = false; | ||||
|         _CDE5.Production__v2_60_0__CDE5__RsM(); | ||||
|         MethodBase methodBase = new StackFrame().GetMethod(); | ||||
|         Assert.IsFalse(string.IsNullOrEmpty(_CDE5.AdaptationTesting.TestContext.FullyQualifiedTestClassName)); | ||||
|         string[] variables = _CDE5.AdaptationTesting.GetVariables(methodBase, check, validatePDSF); | ||||
|         IFileRead fileRead = _CDE5.AdaptationTesting.Get(methodBase, sourceFileLocation: variables[2], sourceFileFilter: variables[3], useCyclicalForDescription: false); | ||||
|         Logistics logistics = new(fileRead); | ||||
|         _ = Shared.AdaptationTesting.ReExtractCompareUpdatePassDirectory(variables, fileRead, logistics, validatePDSF); | ||||
|         NonThrowTryCatch(); | ||||
|     } | ||||
|  | ||||
| } | ||||
| #endif | ||||
							
								
								
									
										45
									
								
								Adaptation/_Tests/Extract/Production/v2.60.0/CDE6-EQPT.cs
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										45
									
								
								Adaptation/_Tests/Extract/Production/v2.60.0/CDE6-EQPT.cs
									
									
									
									
									
										Normal file
									
								
							| @ -0,0 +1,45 @@ | ||||
| #if true | ||||
| using Microsoft.VisualStudio.TestTools.UnitTesting; | ||||
| using System.Diagnostics; | ||||
| using System.Reflection; | ||||
| using System.Threading; | ||||
|  | ||||
| namespace Adaptation._Tests.Extract.Production.v2_60_0; | ||||
|  | ||||
| [TestClass] | ||||
| public class CDE6_EQPT | ||||
| { | ||||
|  | ||||
| #pragma warning disable CA2254 | ||||
| #pragma warning disable IDE0060 | ||||
|  | ||||
|     private static CreateSelfDescription.Production.v2_60_0.CDE6_EQPT _CDE6_EQPT; | ||||
|  | ||||
|     [ClassInitialize] | ||||
|     public static void ClassInitialize(TestContext testContext) | ||||
|     { | ||||
|         CreateSelfDescription.Production.v2_60_0.CDE6_EQPT.ClassInitialize(testContext); | ||||
|         _CDE6_EQPT = CreateSelfDescription.Production.v2_60_0.CDE6_EQPT.EAFLoggingUnitTesting; | ||||
|     } | ||||
|  | ||||
| #if DEBUG | ||||
|     [Ignore] | ||||
| #endif | ||||
|     [TestMethod] | ||||
|     public void Production__v2_60_0__CDE6_EQPT__DownloadRsMFile() => _CDE6_EQPT.Production__v2_60_0__CDE6_EQPT__DownloadRsMFile(); | ||||
|  | ||||
|     [Ignore] | ||||
|     [TestMethod] | ||||
|     public void Production__v2_60_0__CDE6_EQPT__DownloadRsMFile638065099250000000__Normal() | ||||
|     { | ||||
|         bool validatePDSF = false; | ||||
|         string check = "CDE_Logs|WaferMeasurementData.log|.RsM"; | ||||
|         MethodBase methodBase = new StackFrame().GetMethod(); | ||||
|         _CDE6_EQPT.Production__v2_60_0__CDE6_EQPT__DownloadRsMFile(); | ||||
|         _ = _CDE6_EQPT.AdaptationTesting.GetVariables(methodBase, check, validatePDSF); | ||||
|         for (int i = 0; i < int.MaxValue; i++) | ||||
|             Thread.Sleep(500); | ||||
|     } | ||||
|  | ||||
| } | ||||
| #endif | ||||
Some files were not shown because too many files have changed in this diff Show More
		Reference in New Issue
	
	Block a user