diff --git a/UnitTests/PInvoke/FhSvcCtl/FhSvcCtl.csproj b/UnitTests/PInvoke/FhSvcCtl/FhSvcCtl.csproj index 9aa44870..8e3fd4c1 100644 --- a/UnitTests/PInvoke/FhSvcCtl/FhSvcCtl.csproj +++ b/UnitTests/PInvoke/FhSvcCtl/FhSvcCtl.csproj @@ -1,6 +1,7 @@  UnitTest.PInvoke.FhSvcCtl + win10-x64 diff --git a/UnitTests/PInvoke/FhSvcCtl/FhSvcCtlTests.cs b/UnitTests/PInvoke/FhSvcCtl/FhSvcCtlTests.cs index 82935381..bf80ee33 100644 --- a/UnitTests/PInvoke/FhSvcCtl/FhSvcCtlTests.cs +++ b/UnitTests/PInvoke/FhSvcCtl/FhSvcCtlTests.cs @@ -1,7 +1,5 @@ using NUnit.Framework; using NUnit.Framework.Internal; -using System; -using System.Runtime.InteropServices; using static Vanara.PInvoke.FhSvcCtl; namespace Vanara.PInvoke.Tests @@ -9,23 +7,6 @@ namespace Vanara.PInvoke.Tests [TestFixture] public class FhSvcCtlTests { - [OneTimeSetUp] - public void _Setup() - { - } - - [DllImport(Lib.Kernel32, CharSet = CharSet.Auto, SetLastError = true, BestFitMapping = false, ThrowOnUnmappableChar = true)] - static extern HINSTANCE LoadLibraryEx(string lpFileName, [Optional] IntPtr hFile, uint dwFlags); - - [DllImport(Lib.Kernel32, SetLastError = true, ExactSpelling = true)] - [return: MarshalAs(UnmanagedType.Bool)] - static extern bool FreeLibrary(HINSTANCE hModule); - - [OneTimeTearDown] - public void _TearDown() - { - } - [Test] public void TestIntf() { @@ -36,10 +17,6 @@ namespace Vanara.PInvoke.Tests [Test] public void TestFn() { - HINSTANCE hi; - Assert.That(hi = LoadLibraryEx(@"C:\Windows\System32\fhsvccfg.dll", default, 0x1000), ResultIs.ValidHandle); - FreeLibrary(hi); - Assert.That(FhServiceOpenPipe(true, out var hPipe), ResultIs.Successful); Assert.That(FhServiceReloadConfiguration(hPipe), ResultIs.Successful); Assert.That(FhServiceStartBackup(hPipe, true), ResultIs.Successful);