Aggiutna altre classi di testing...
This commit is contained in:
@@ -39,17 +39,27 @@
|
||||
<WarningLevel>4</WarningLevel>
|
||||
</PropertyGroup>
|
||||
<ItemGroup>
|
||||
<Reference Include="Microsoft.CSharp" />
|
||||
<Reference Include="Microsoft.VisualStudio.TestPlatform.TestFramework, Version=14.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a, processorArchitecture=MSIL">
|
||||
<HintPath>..\packages\MSTest.TestFramework.1.4.0\lib\net45\Microsoft.VisualStudio.TestPlatform.TestFramework.dll</HintPath>
|
||||
</Reference>
|
||||
<Reference Include="Microsoft.VisualStudio.TestPlatform.TestFramework.Extensions, Version=14.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a, processorArchitecture=MSIL">
|
||||
<HintPath>..\packages\MSTest.TestFramework.1.4.0\lib\net45\Microsoft.VisualStudio.TestPlatform.TestFramework.Extensions.dll</HintPath>
|
||||
</Reference>
|
||||
<Reference Include="NLog, Version=4.0.0.0, Culture=neutral, PublicKeyToken=5120e14c03d0593c, processorArchitecture=MSIL">
|
||||
<HintPath>..\packages\NLog.4.6.3\lib\net45\NLog.dll</HintPath>
|
||||
</Reference>
|
||||
<Reference Include="System" />
|
||||
<Reference Include="System.Buffers, Version=4.0.3.0, Culture=neutral, PublicKeyToken=cc7b13ffcd2ddd51, processorArchitecture=MSIL">
|
||||
<HintPath>..\packages\System.Buffers.4.5.0\lib\netstandard2.0\System.Buffers.dll</HintPath>
|
||||
</Reference>
|
||||
<Reference Include="System.Configuration" />
|
||||
<Reference Include="System.Core" />
|
||||
<Reference Include="System.Data" />
|
||||
<Reference Include="System.IO.Compression, Version=4.2.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089, processorArchitecture=MSIL" />
|
||||
<Reference Include="System.IO.Pipelines, Version=4.0.0.1, Culture=neutral, PublicKeyToken=cc7b13ffcd2ddd51, processorArchitecture=MSIL">
|
||||
<HintPath>..\packages\System.IO.Pipelines.4.5.3\lib\netstandard2.0\System.IO.Pipelines.dll</HintPath>
|
||||
</Reference>
|
||||
<Reference Include="System.Memory, Version=4.0.1.1, Culture=neutral, PublicKeyToken=cc7b13ffcd2ddd51, processorArchitecture=MSIL">
|
||||
<HintPath>..\packages\System.Memory.4.5.3\lib\netstandard2.0\System.Memory.dll</HintPath>
|
||||
</Reference>
|
||||
@@ -60,6 +70,13 @@
|
||||
<Reference Include="System.Runtime.CompilerServices.Unsafe, Version=4.0.4.1, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a, processorArchitecture=MSIL">
|
||||
<HintPath>..\packages\System.Runtime.CompilerServices.Unsafe.4.5.2\lib\netstandard2.0\System.Runtime.CompilerServices.Unsafe.dll</HintPath>
|
||||
</Reference>
|
||||
<Reference Include="System.Runtime.Serialization" />
|
||||
<Reference Include="System.ServiceModel" />
|
||||
<Reference Include="System.Threading.Tasks.Extensions, Version=4.2.0.0, Culture=neutral, PublicKeyToken=cc7b13ffcd2ddd51, processorArchitecture=MSIL">
|
||||
<HintPath>..\packages\System.Threading.Tasks.Extensions.4.5.2\lib\netstandard2.0\System.Threading.Tasks.Extensions.dll</HintPath>
|
||||
</Reference>
|
||||
<Reference Include="System.Transactions" />
|
||||
<Reference Include="System.Xml" />
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<Compile Include="TestSuite.cs" />
|
||||
|
||||
@@ -126,7 +126,7 @@ namespace MCC_UnitTest
|
||||
#endregion
|
||||
|
||||
[TestMethod]
|
||||
public void Test_init_01()
|
||||
public void Test_setup_01()
|
||||
{
|
||||
// reset x iniziare...
|
||||
if (_cts != null)
|
||||
@@ -143,6 +143,32 @@ namespace MCC_UnitTest
|
||||
//// init async...
|
||||
//var taskResult = MCC.InitSDKAsync(confFilePath, CancellationToken.None);
|
||||
|
||||
//// salvo il risultato restituito...
|
||||
//reqStatus = taskResult.Result;
|
||||
|
||||
//// test!
|
||||
//Assert.IsNotNull(reqStatus);
|
||||
}
|
||||
|
||||
[TestMethod]
|
||||
public void Test_init_01()
|
||||
{
|
||||
// reset x iniziare...
|
||||
if (_cts != null)
|
||||
{
|
||||
_cts.Cancel();
|
||||
}
|
||||
|
||||
// NUOVA istanza da file di conf...
|
||||
MCC = new MConnectClient();
|
||||
|
||||
// init async...
|
||||
var taskResult = MCC.InitSDKAsync(confFilePath, CancellationToken.None);
|
||||
|
||||
// test!
|
||||
Assert.IsNotNull(taskResult.Result);
|
||||
|
||||
|
||||
//// salvo il risultato restituito...
|
||||
//reqStatus = taskResult.Result;
|
||||
|
||||
|
||||
@@ -14,6 +14,14 @@
|
||||
<assemblyIdentity name="System.Buffers" publicKeyToken="cc7b13ffcd2ddd51" culture="neutral" />
|
||||
<bindingRedirect oldVersion="0.0.0.0-4.0.3.0" newVersion="4.0.3.0" />
|
||||
</dependentAssembly>
|
||||
<dependentAssembly>
|
||||
<assemblyIdentity name="System.Runtime.CompilerServices.Unsafe" publicKeyToken="b03f5f7f11d50a3a" culture="neutral" />
|
||||
<bindingRedirect oldVersion="0.0.0.0-4.0.4.1" newVersion="4.0.4.1" />
|
||||
</dependentAssembly>
|
||||
<dependentAssembly>
|
||||
<assemblyIdentity name="System.IO.Pipelines" publicKeyToken="cc7b13ffcd2ddd51" culture="neutral" />
|
||||
<bindingRedirect oldVersion="0.0.0.0-4.0.0.1" newVersion="4.0.0.1" />
|
||||
</dependentAssembly>
|
||||
</assemblyBinding>
|
||||
</runtime>
|
||||
</configuration>
|
||||
@@ -2,8 +2,11 @@
|
||||
<packages>
|
||||
<package id="MSTest.TestAdapter" version="1.4.0" targetFramework="net462" />
|
||||
<package id="MSTest.TestFramework" version="1.4.0" targetFramework="net462" />
|
||||
<package id="NLog" version="4.6.3" targetFramework="net462" />
|
||||
<package id="System.Buffers" version="4.5.0" targetFramework="net462" />
|
||||
<package id="System.IO.Pipelines" version="4.5.3" targetFramework="net462" />
|
||||
<package id="System.Memory" version="4.5.3" targetFramework="net462" />
|
||||
<package id="System.Numerics.Vectors" version="4.5.0" targetFramework="net462" />
|
||||
<package id="System.Runtime.CompilerServices.Unsafe" version="4.5.2" targetFramework="net462" />
|
||||
<package id="System.Threading.Tasks.Extensions" version="4.5.2" targetFramework="net462" />
|
||||
</packages>
|
||||
@@ -9,22 +9,7 @@ namespace MConnectSDK
|
||||
public static Logger Instance { get; private set; }
|
||||
static Log()
|
||||
{
|
||||
#if DEBUG
|
||||
// Setup the logging view for Sentinel - http://sentinel.codeplex.com
|
||||
var sentinalTarget = new NLogViewerTarget()
|
||||
{
|
||||
Name = "sentinal",
|
||||
Address = "udp://127.0.0.1:9999",
|
||||
IncludeNLogData = false
|
||||
};
|
||||
var sentinalRule = new LoggingRule("*", LogLevel.Trace, sentinalTarget);
|
||||
LogManager.Configuration.AddTarget("sentinal", sentinalTarget);
|
||||
LogManager.Configuration.LoggingRules.Add(sentinalRule);
|
||||
|
||||
#endif
|
||||
|
||||
LogManager.ReconfigExistingLoggers();
|
||||
|
||||
Instance = LogManager.GetCurrentClassLogger();
|
||||
}
|
||||
}
|
||||
|
||||
@@ -617,7 +617,6 @@ namespace MConnectSDK
|
||||
/// <summary>
|
||||
public MConnectClient()
|
||||
{
|
||||
|
||||
confParam param = new confParam();
|
||||
ML = new memLayer(param);
|
||||
}
|
||||
|
||||
@@ -23,6 +23,10 @@
|
||||
<assemblyIdentity name="System.Runtime.CompilerServices.Unsafe" publicKeyToken="b03f5f7f11d50a3a" culture="neutral" />
|
||||
<bindingRedirect oldVersion="0.0.0.0-4.0.4.1" newVersion="4.0.4.1" />
|
||||
</dependentAssembly>
|
||||
<dependentAssembly>
|
||||
<assemblyIdentity name="System.Memory" publicKeyToken="cc7b13ffcd2ddd51" culture="neutral" />
|
||||
<bindingRedirect oldVersion="0.0.0.0-4.0.1.1" newVersion="4.0.1.1" />
|
||||
</dependentAssembly>
|
||||
</assemblyBinding>
|
||||
</runtime>
|
||||
</configuration>
|
||||
@@ -84,8 +84,8 @@
|
||||
<Reference Include="System.IO.Pipelines, Version=4.0.0.1, Culture=neutral, PublicKeyToken=cc7b13ffcd2ddd51, processorArchitecture=MSIL">
|
||||
<HintPath>..\packages\System.IO.Pipelines.4.5.3\lib\netstandard2.0\System.IO.Pipelines.dll</HintPath>
|
||||
</Reference>
|
||||
<Reference Include="System.Memory, Version=4.0.1.0, Culture=neutral, PublicKeyToken=cc7b13ffcd2ddd51, processorArchitecture=MSIL">
|
||||
<HintPath>..\packages\System.Memory.4.5.2\lib\netstandard2.0\System.Memory.dll</HintPath>
|
||||
<Reference Include="System.Memory, Version=4.0.1.1, Culture=neutral, PublicKeyToken=cc7b13ffcd2ddd51, processorArchitecture=MSIL">
|
||||
<HintPath>..\packages\System.Memory.4.5.3\lib\netstandard2.0\System.Memory.dll</HintPath>
|
||||
</Reference>
|
||||
<Reference Include="System.Numerics" />
|
||||
<Reference Include="System.Numerics.Vectors, Version=4.1.4.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a, processorArchitecture=MSIL">
|
||||
|
||||
@@ -11,7 +11,7 @@
|
||||
<package id="System.Diagnostics.PerformanceCounter" version="4.5.0" targetFramework="net462" />
|
||||
<package id="System.Drawing.Common" version="4.5.1" targetFramework="net462" />
|
||||
<package id="System.IO.Pipelines" version="4.5.3" targetFramework="net462" />
|
||||
<package id="System.Memory" version="4.5.2" targetFramework="net462" />
|
||||
<package id="System.Memory" version="4.5.3" targetFramework="net462" />
|
||||
<package id="System.Net.Http" version="4.3.4" targetFramework="net462" />
|
||||
<package id="System.Numerics.Vectors" version="4.5.0" targetFramework="net462" />
|
||||
<package id="System.Runtime.CompilerServices.Unsafe" version="4.5.2" targetFramework="net462" />
|
||||
|
||||
Reference in New Issue
Block a user