Remove XUnit tests
authorAleksandr Shaurtaev <a.shaurtaev@partner.samsung.com>
Tue, 30 Aug 2022 15:08:09 +0000 (18:08 +0300)
committerGleb Balykov/Platform Lab /SRR/Staff Engineer/Samsung Electronics <g.balykov@samsung.com>
Tue, 6 Dec 2022 18:49:48 +0000 (21:49 +0300)
test-suite/README.md
test-suite/XunitTests/LocalTest.cs [deleted file]
test-suite/XunitTests/XunitTests.csproj [deleted file]

index 26873807c45fa45cee45d74046995c2f843769c4..57f84fde61ec209c2efc8ca3e564a039b656dbb3 100644 (file)
@@ -89,13 +89,6 @@ to make all necessary steps.
     $ powershell.exe -executionpolicy bypass -File run_tests.ps1 <test-name> [<test-name>]
 ```
 
-- Xunit tests:
-```
-    $ cd XunitTests
-    $ dotnet test
-```
-
-
 # How to add new test
 
 - move to test-suite directory;
@@ -117,12 +110,4 @@ to make all necessary steps.
 
 - add test name into ALL_TEST_NAMES list in "run_tests.sh", "run_tests.ps1", "sdb_run_tests.sh" and "sdb_run_tests.ps1" scripts;
 
-- add reference to NewTest project in Xunit tests:
-```
-    $ cd XunitTests
-    $ dotnet add reference ../NewTest/NewTest.csproj
-```
-
-- add attribute `[InlineData("NewTest")]` in xunit test class before method `Run()`;
-
 - in MIExampleTest implemented small scenario of NetCoreDbgTest library using.
diff --git a/test-suite/XunitTests/LocalTest.cs b/test-suite/XunitTests/LocalTest.cs
deleted file mode 100644 (file)
index 64e2c82..0000000
+++ /dev/null
@@ -1,144 +0,0 @@
-using System;
-using System.IO;
-using Xunit;
-
-using LocalDebugger;
-using NetcoreDbgTestCore;
-using NetcoreDbgTestCore.MI;
-using NetcoreDbgTestCore.VSCode;
-
-namespace XUnitTests
-{
-    public class LocalTest : IDisposable
-    {
-        public LocalTest()
-        {
-            DebuggerClient = null;
-            LocalDebugger = null;
-        }
-
-        [Theory]
-        [InlineData("MIExampleTest", "Program.cs;Program_second_source.cs")]
-        [InlineData("MITestBreakpoint", "Program.cs")]
-        [InlineData("MITestExpression", "Program.cs")]
-        [InlineData("MITestVariables", "Program.cs")]
-        [InlineData("MITestStepping", "Program.cs")]
-        [InlineData("MITestEvaluate", "Program.cs")]
-        [InlineData("MITestException", "Program.cs")]
-        [InlineData("MITestEnv", "Program.cs")]
-        [InlineData("MITestGDB", "Program.cs")]
-        [InlineData("MITestExecAbort", "Program.cs")]
-        [InlineData("MITestExecInt", "Program.cs")]
-        [InlineData("MITestHandshake", "Program.cs")]
-        [InlineData("MITestTarget", "Program.cs")]
-        [InlineData("MITestExceptionBreakpoint", "Program.cs")]
-        [InlineData("MITestExitCode", "Program.cs")]
-        [InlineData("MITestEvalNotEnglish", "Program.cs")]
-        [InlineData("MITest中文目录", "中文文件名.cs")]
-        [InlineData("MITestSrcBreakpointResolve", "Program.cs;folder/Program.cs")]
-        [InlineData("MITestEnum", "Program.cs")]
-        [InlineData("MITestBreak", "Program.cs")]
-        [InlineData("MITestBreakpointToModule", "Program.cs")]
-        [InlineData("MITestAsyncStepping", "Program.cs")]
-        [InlineData("MITestNoJMCNoFilterStepping", "Program.cs")]
-        [InlineData("MITestNoJMCBreakpoint", "Program.cs")]
-        [InlineData("MITestNoJMCAsyncStepping", "Program.cs")]
-        [InlineData("MITestNoJMCExceptionBreakpoint", "Program.cs")]
-        [InlineData("MITestSizeof", "Program.cs")]
-        [InlineData("MITestAsyncLambdaEvaluate", "Program.cs")]
-        [InlineData("MITestGeneric", "Program.cs")]
-        [InlineData("MITestEvalArraysIndexers", "Program.cs")]
-        [InlineData("VSCodeExampleTest", "Program.cs")]
-        [InlineData("VSCodeTestBreakpoint", "Program.cs")]
-        [InlineData("VSCodeTestFuncBreak", "Program.cs")]
-        [InlineData("VSCodeTestAttach", "Program.cs")]
-        [InlineData("VSCodeTestPause", "Program.cs")]
-        [InlineData("VSCodeTestDisconnect", "Program.cs")]
-        [InlineData("VSCodeTestThreads", "Program.cs")]
-        [InlineData("VSCodeTestVariables", "Program.cs")]
-        [InlineData("VSCodeTestEvaluate", "Program.cs")]
-        [InlineData("VSCodeTestStepping", "Program.cs")]
-        [InlineData("VSCodeTestEnv", "Program.cs")]
-        [InlineData("VSCodeTestExitCode", "Program.cs")]
-        [InlineData("VSCodeTestEvalNotEnglish", "Program.cs")]
-        [InlineData("VSCodeTest中文目录", "中文文件名.cs")]
-        [InlineData("VSCodeTestSrcBreakpointResolve", "Program.cs;folder/Program.cs")]
-        [InlineData("VSCodeTestEnum", "Program.cs")]
-        [InlineData("VSCodeTestAsyncStepping", "Program.cs")]
-        [InlineData("VSCodeTestBreak", "Program.cs")]
-        [InlineData("VSCodeTestNoJMCNoFilterStepping", "Program.cs")]
-        [InlineData("VSCodeTestNoJMCBreakpoint", "Program.cs")]
-        [InlineData("VSCodeTestNoJMCAsyncStepping", "Program.cs")]
-        [InlineData("VSCodeTestExceptionBreakpoint", "Program.cs")]
-        [InlineData("VSCodeTestNoJMCExceptionBreakpoint", "Program.cs")]
-        [InlineData("VSCodeTestSizeof", "Program.cs")]
-        [InlineData("VSCodeTestAsyncLambdaEvaluate", "Program.cs")]
-        [InlineData("VSCodeTestGeneric", "Program.cs")]
-        [InlineData("VSCodeTestEvalArraysIndexers", "Program.cs")]
-        public void Run(string testCaseName, string testCourceList)
-        {
-            // Explicit encoding setup, since system console encoding could be not utf8 (Windows OS).
-            // Note, netcoredbg aimed to interact with utf8 encoding usage only for all protocols.
-            Console.OutputEncoding = System.Text.Encoding.UTF8;
-            Console.InputEncoding = System.Text.Encoding.UTF8;
-
-            string testSuiteRoot = Path.GetFullPath(
-                Path.Combine(Directory.GetCurrentDirectory(), "../../../..")
-            );
-
-            var Env = new NetcoreDbgTestCore.Environment();
-            Env.TestName = testCaseName;
-
-            string[] testFileArray = testCourceList.Split(";");
-            foreach (var FileName in testFileArray) {
-                Env.SourceFilesPath += Path.Combine(testSuiteRoot, testCaseName, FileName + ";");
-            }
-            Env.SourceFilesPath = Env.SourceFilesPath.Remove(Env.SourceFilesPath.Length - 1);
-
-            Env.TargetAssemblyPath = Path.Combine(testSuiteRoot,
-                testCaseName + "/bin/Debug/netcoreapp3.1/",
-                testCaseName + ".dll");
-            string fullDebuggerPath = Path.GetFullPath(Path.Combine(testSuiteRoot, DebuggerPath));
-
-            if (testCaseName.StartsWith("MI")) {
-                LocalDebugger = new LocalDebuggerProcess(fullDebuggerPath, @" --interpreter=mi");
-                LocalDebugger.Start();
-                DebuggerClient = new MILocalDebuggerClient(LocalDebugger.Input,
-                                                           LocalDebugger.Output);
-            } else if (testCaseName.StartsWith("VSCode")) {
-                LocalDebugger = new LocalDebuggerProcess(fullDebuggerPath, @" --interpreter=vscode");
-                LocalDebugger.Start();
-                DebuggerClient = new VSCodeLocalDebuggerClient(LocalDebugger.Input,
-                                                               LocalDebugger.Output);
-            } else {
-                throw new System.Exception();
-            }
-
-            Xunit.Assert.True(DebuggerClient.DoHandshake(5000));
-
-            var Script = new ControlScript(Env.SourceFilesPath, DebuggerClient.Protocol);
-
-            new ControlPart().Run(Script, DebuggerClient, Env);
-        }
-
-        public void Dispose()
-        {
-            if (DebuggerClient != null) {
-                DebuggerClient.Close();
-            }
-            if (LocalDebugger != null) {
-                // we may exit debugger by "gdb-exit" call in command script
-                try
-                {
-                    LocalDebugger.Close();
-                }
-                // "No such process" exception at System.Diagnostics.Process.Kill()
-                catch (System.ComponentModel.Win32Exception) {}
-            }
-        }
-
-        LocalDebuggerProcess LocalDebugger;
-        DebuggerClient DebuggerClient;
-        static string DebuggerPath = "../bin/netcoredbg";
-    }
-}
diff --git a/test-suite/XunitTests/XunitTests.csproj b/test-suite/XunitTests/XunitTests.csproj
deleted file mode 100644 (file)
index 772efec..0000000
+++ /dev/null
@@ -1,85 +0,0 @@
-<Project Sdk="Microsoft.NET.Sdk">\r
-\r
-  <PropertyGroup>\r
-    <TargetFramework>netcoreapp3.1</TargetFramework>\r
-\r
-    <IsPackable>false</IsPackable>\r
-  </PropertyGroup>\r
-\r
-  <ItemGroup Condition="(('$(TargetFrameworkIdentifier)' == '.NETCoreApp' AND '$(_TargetFrameworkVersionWithoutV)' &lt; '6.0'))">\r
-    <PackageReference Include="Microsoft.CodeAnalysis" Version="2.10.0" />\r
-  </ItemGroup>\r
-\r
-  <ItemGroup Condition="(('$(TargetFrameworkIdentifier)' == '.NETCoreApp' AND '$(_TargetFrameworkVersionWithoutV)' &gt;= '6.0'))">\r
-    <PackageReference Include="Microsoft.CodeAnalysis" Version="4.0.1" />\r
-  </ItemGroup>\r
-\r
-  <ItemGroup>\r
-    <PackageReference Include="Microsoft.NET.Test.Sdk" Version="15.9.0" />\r
-    <PackageReference Include="xunit" Version="2.4.1" />\r
-    <PackageReference Include="xunit.runner.visualstudio" Version="2.4.1" />\r
-  </ItemGroup>\r
-\r
-  <ItemGroup>\r
-    <ProjectReference Include="..\LocalDebugger\LocalDebugger.csproj" />\r
-    <ProjectReference Include="..\NetcoreDbgTest\NetcoreDbgTest.csproj" />\r
-    <ProjectReference Include="..\MIExampleTest\MIExampleTest.csproj" />\r
-    <ProjectReference Include="..\MITestStepping\MITestStepping.csproj" />\r
-    <ProjectReference Include="..\MITestException\MITestException.csproj" />\r
-    <ProjectReference Include="..\MITestExpression\MITestExpression.csproj" />\r
-    <ProjectReference Include="..\MITestVariables\MITestVariables.csproj" />\r
-    <ProjectReference Include="..\MITestEvaluate\MITestEvaluate.csproj" />\r
-    <ProjectReference Include="..\MITestBreakpoint\MITestBreakpoint.csproj" />\r
-    <ProjectReference Include="..\MITestEnv\MITestEnv.csproj" />\r
-    <ProjectReference Include="..\MITestGDB\MITestGDB.csproj" />\r
-    <ProjectReference Include="..\MITestExecAbort\MITestExecAbort.csproj" />\r
-    <ProjectReference Include="..\MITestExecInt\MITestExecInt.csproj" />\r
-    <ProjectReference Include="..\MITestHandshake\MITestHandshake.csproj" />\r
-    <ProjectReference Include="..\MITestTarget\MITestTarget.csproj" />\r
-    <ProjectReference Include="..\MITestExceptionBreakpoint\MITestExceptionBreakpoint.csproj" />\r
-    <ProjectReference Include="..\MITestExitCode\MITestExitCode.csproj" />\r
-    <ProjectReference Include="..\MITestEvalNotEnglish\MITestEvalNotEnglish.csproj" />\r
-    <ProjectReference Include="..\MITest中文目录\MITest中文目录.csproj" />\r
-    <ProjectReference Include="..\MITestSrcBreakpointResolve\MITestSrcBreakpointResolve.csproj" />\r
-    <ProjectReference Include="..\MITestEnum\MITestEnum.csproj" />\r
-    <ProjectReference Include="..\MITestAsyncStepping\MITestAsyncStepping.csproj" />\r
-    <ProjectReference Include="..\MITestBreak\MITestBreak.csproj" />\r
-    <ProjectReference Include="..\MITestBreakpointToModule\MITestBreakpointToModule.csproj" />\r
-    <ProjectReference Include="..\MITestNoJMCNoFilterStepping\MITestNoJMCNoFilterStepping.csproj" />\r
-    <ProjectReference Include="..\MITestNoJMCBreakpoint\MITestNoJMCBreakpoint.csproj" />\r
-    <ProjectReference Include="..\MITestNoJMCAsyncStepping\MITestNoJMCAsyncStepping.csproj" />\r
-    <ProjectReference Include="..\MITestNoJMCExceptionBreakpoint\MITestNoJMCExceptionBreakpoint.csproj" />\r
-    <ProjectReference Include="..\VSCodeExampleTest\VSCodeExampleTest.csproj" />\r
-    <ProjectReference Include="..\VSCodeTestBreakpoint\VSCodeTestBreakpoint.csproj" />\r
-    <ProjectReference Include="..\VSCodeTestFuncBreak\VSCodeTestFuncBreak.csproj" />\r
-    <ProjectReference Include="..\VSCodeTestAttach\VSCodeTestAttach.csproj" />\r
-    <ProjectReference Include="..\VSCodeTestPause\VSCodeTestPause.csproj" />\r
-    <ProjectReference Include="..\VSCodeTestDisconnect\VSCodeTestDisconnect.csproj" />\r
-    <ProjectReference Include="..\VSCodeTestThreads\VSCodeTestThreads.csproj" />\r
-    <ProjectReference Include="..\VSCodeTestVariables\VSCodeTestVariables.csproj" />\r
-    <ProjectReference Include="..\VSCodeTestEvaluate\VSCodeTestEvaluate.csproj" />\r
-    <ProjectReference Include="..\VSCodeTestStepping\VSCodeTestStepping.csproj" />\r
-    <ProjectReference Include="..\VSCodeTestEnv\VSCodeTestEnv.csproj" />\r
-    <ProjectReference Include="..\VSCodeTestExitCode\VSCodeTestExitCode.csproj" />\r
-    <ProjectReference Include="..\VSCodeTestEvalNotEnglish\VSCodeTestEvalNotEnglish.csproj" />\r
-    <ProjectReference Include="..\VSCodeTest中文目录\VSCodeTest中文目录.csproj" />\r
-    <ProjectReference Include="..\VSCodeTestSrcBreakpointResolve\VSCodeTestSrcBreakpointResolve.csproj" />\r
-    <ProjectReference Include="..\VSCodeTestEnum\VSCodeTestEnum.csproj" />\r
-    <ProjectReference Include="..\VSCodeTestAsyncStepping\VSCodeTestAsyncStepping.csproj" />\r
-    <ProjectReference Include="..\VSCodeTestBreak\VSCodeTestBreak.csproj" />\r
-    <ProjectReference Include="..\VSCodeTestNoJMCNoFilterStepping\VSCodeTestNoJMCNoFilterStepping.csproj" />\r
-    <ProjectReference Include="..\VSCodeTestNoJMCBreakpoint\VSCodeTestNoJMCBreakpoint.csproj" />\r
-    <ProjectReference Include="..\VSCodeTestNoJMCAsyncStepping\VSCodeTestNoJMCAsyncStepping.csproj" />\r
-    <ProjectReference Include="..\VSCodeTestExceptionBreakpoint\VSCodeTestExceptionBreakpoint.csproj" />\r
-    <ProjectReference Include="..\VSCodeTestNoJMCExceptionBreakpoint\VSCodeTestNoJMCExceptionBreakpoint.csproj" />\r
-    <ProjectReference Include="..\MITestSizeof\MITestSizeof.csproj" />\r
-    <ProjectReference Include="..\VSCodeTestSizeof\VSCodeTestSizeof.csproj" />\r
-    <ProjectReference Include="..\MITestAsyncLambdaEvaluate\MITestAsyncLambdaEvaluate.csproj" />\r
-    <ProjectReference Include="..\VSCodeTestAsyncLambdaEvaluate\VSCodeTestAsyncLambdaEvaluate.csproj" />\r
-    <ProjectReference Include="..\VSCodeTestGeneric\VSCodeTestGeneric.csproj" />\r
-    <ProjectReference Include="..\MITestGeneric\MITestGeneric.csproj" />\r
-    <ProjectReference Include="..\VSCodeTestEvalArraysIndexers\VSCodeTestEvalArraysIndexers.csproj" />\r
-    <ProjectReference Include="..\MITestEvalArraysIndexers\MITestEvalArraysIndexers.csproj" />\r
-  </ItemGroup>\r
-\r
-</Project>\r