浏览代码

Added WorkItem property on some test relating to Issue #703
Added Visual Studio Test Meta Data File, to organize tests abit. (Not completed)

Kenneth_aa_cp 14 年之前
父节点
当前提交
a9d1ba340c

+ 3 - 3
Renci.SshClient/Renci.SshNet.Tests/ConnectionTest.cs

@@ -132,21 +132,21 @@ namespace Renci.SshNet.Tests
             }
         }
 
-        [TestMethod]
+		[WorkItem(703), TestMethod]
         [ExpectedException(typeof(ArgumentNullException))]
         public void Test_ConnectionInfo_NullHost()
         {
             var connectionInfo = new PasswordConnectionInfo(null, null, null);
         }
 
-        [TestMethod]
+		[WorkItem(703), TestMethod]
         [ExpectedException(typeof(ArgumentOutOfRangeException))]
         public void Test_ConnectionInfo_SmallPortNumber()
         {
             var connectionInfo = new PasswordConnectionInfo(Resources.HOST, IPEndPoint.MinPort - 1, null, null);
         }
 
-        [TestMethod]
+		[WorkItem(703), TestMethod]
         [ExpectedException(typeof(ArgumentOutOfRangeException))]
         public void Test_ConnectionInfo_BigPortNumber()
         {

+ 2 - 2
Renci.SshClient/Renci.SshNet.Tests/Security/TestPrivateKeyFile.cs

@@ -10,7 +10,7 @@ namespace Renci.SshNet.Tests.Security
     [TestClass]
     public class TestPrivateKeyFile
     {
-        [TestMethod]
+		[WorkItem(703), TestMethod]
         [ExpectedException(typeof(ArgumentNullException))]
         public void Test_PrivateKeyFile_EmptyFileName()
         {
@@ -18,7 +18,7 @@ namespace Renci.SshNet.Tests.Security
             var keyFile = new PrivateKeyFile(fileName);
         }
 
-        [TestMethod]
+		[WorkItem(703), TestMethod]
         [ExpectedException(typeof(ArgumentNullException))]
         public void Test_PrivateKeyFile_StreamIsNull()
         {

+ 1 - 1
Renci.SshClient/Renci.SshNet.Tests/SshClientTests/TestSshCommand.cs

@@ -350,7 +350,7 @@ namespace Renci.SshNet.Tests.SshClientTests
         }
 
 
-        [TestMethod]
+		[WorkItem(703), TestMethod]
         [ExpectedException(typeof(ArgumentException))]
         public void Test_EndExecute_Before_BeginExecute()
         {

+ 4 - 1
Renci.SshClient/Renci.SshNet.sln

@@ -4,6 +4,9 @@ Microsoft Visual Studio Solution File, Format Version 11.00
 Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "Renci.SshNet", "Renci.SshNet\Renci.SshNet.csproj", "{2F5F8C90-0BD1-424F-997C-7BC6280919D1}"
 EndProject
 Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "Solution Items", "Solution Items", "{A3063E62-89D5-43FF-AB1A-FFBECB4A1850}"
+	ProjectSection(SolutionItems) = preProject
+		Renci.SshNet.vsmdi = Renci.SshNet.vsmdi
+	EndProjectSection
 EndProject
 Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "Renci.SshNet.Tests", "Renci.SshNet.Tests\Renci.SshNet.Tests.csproj", "{C45379B9-17B1-4E89-BC2E-6D41726413E8}"
 EndProject
@@ -21,7 +24,7 @@ Global
 		SccLocalPath2 = Renci.SshNet.Tests
 	EndGlobalSection
 	GlobalSection(TestCaseManagementSettings) = postSolution
-		CategoryFile = Renci.SshClient1.vsmdi
+		CategoryFile = Renci.SshNet.vsmdi
 	EndGlobalSection
 	GlobalSection(SolutionConfigurationPlatforms) = preSolution
 		Debug|Any CPU = Debug|Any CPU

+ 35 - 0
Renci.SshClient/Renci.SshNet.vsmdi

@@ -0,0 +1,35 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<TestLists xmlns="http://microsoft.com/schemas/VisualStudio/TeamTest/2010">
+  <TestList name="SftpClient" id="1405242d-fd39-46f3-88aa-a561b16d9136" parentListId="8c43106b-9dc1-4907-a29f-aa66a61bf5b6">
+    <Description>Tests that affect SftpClient.</Description>
+    <TestLinks>
+      <TestLink id="3305f837-8225-85c8-f1e9-c36ad7e38db9" name="Test_Get_Invalid_Directory" storage="renci.sshnet.tests\bin\debug\renci.sshnet.tests.dll" type="Microsoft.VisualStudio.TestTools.TestTypes.Unit.UnitTestElement, Microsoft.VisualStudio.QualityTools.Tips.UnitTest.ObjectModel, Version=10.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a" />
+      <TestLink id="a2a0b9e4-ae8f-562d-9a9e-e8b999ce0e72" name="Test_Sftp_Ensure_Async_Delegates_Called_For_BeginFileUpload_BeginFileDownload_BeginListDirectory" storage="renci.sshnet.tests\bin\debug\renci.sshnet.tests.dll" type="Microsoft.VisualStudio.TestTools.TestTypes.Unit.UnitTestElement, Microsoft.VisualStudio.QualityTools.Tips.UnitTest.ObjectModel, Version=10.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a" />
+      <TestLink id="7c8b8c07-1c12-c2f3-fa49-520c689784e8" name="Test_Sftp_ListDirectory_Current" storage="renci.sshnet.tests\bin\debug\renci.sshnet.tests.dll" type="Microsoft.VisualStudio.TestTools.TestTypes.Unit.UnitTestElement, Microsoft.VisualStudio.QualityTools.Tips.UnitTest.ObjectModel, Version=10.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a" />
+      <TestLink id="566be3e3-7344-2506-a01e-b2858b86453f" name="Test_Sftp_DeleteDirectory_Which_No_Permissions" storage="renci.sshnet.tests\bin\debug\renci.sshnet.tests.dll" type="Microsoft.VisualStudio.TestTools.TestTypes.Unit.UnitTestElement, Microsoft.VisualStudio.QualityTools.Tips.UnitTest.ObjectModel, Version=10.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a" />
+      <TestLink id="69e19f40-2e27-b25b-db00-4f960242a34b" name="Test_Sftp_ListDirectory_Without_Connecting" storage="renci.sshnet.tests\bin\debug\renci.sshnet.tests.dll" type="Microsoft.VisualStudio.TestTools.TestTypes.Unit.UnitTestElement, Microsoft.VisualStudio.QualityTools.Tips.UnitTest.ObjectModel, Version=10.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a" />
+      <TestLink id="cea8b905-fcf5-11e0-972a-3b87e3b06d10" name="Test_Sftp_DeleteDirectory_Without_Connecting" storage="renci.sshnet.tests\bin\debug\renci.sshnet.tests.dll" type="Microsoft.VisualStudio.TestTools.TestTypes.Unit.UnitTestElement, Microsoft.VisualStudio.QualityTools.Tips.UnitTest.ObjectModel, Version=10.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a" />
+      <TestLink id="a3afb0a2-ca8b-d745-4584-8564f70689eb" name="Test_Sftp_DeleteDirectory_Which_Doesnt_Exists" storage="renci.sshnet.tests\bin\debug\renci.sshnet.tests.dll" type="Microsoft.VisualStudio.TestTools.TestTypes.Unit.UnitTestElement, Microsoft.VisualStudio.QualityTools.Tips.UnitTest.ObjectModel, Version=10.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a" />
+      <TestLink id="5e6b8258-8ab1-4d79-15bf-b5267cbb85ac" name="Test_Sftp_ListDirectory_Empty" storage="renci.sshnet.tests\bin\debug\renci.sshnet.tests.dll" type="Microsoft.VisualStudio.TestTools.TestTypes.Unit.UnitTestElement, Microsoft.VisualStudio.QualityTools.Tips.UnitTest.ObjectModel, Version=10.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a" />
+      <TestLink id="73191d59-b774-74ef-7cdd-feab7acd6ed5" name="Test_Sftp_CreateDirectory_Already_Exists" storage="renci.sshnet.tests\bin\debug\renci.sshnet.tests.dll" type="Microsoft.VisualStudio.TestTools.TestTypes.Unit.UnitTestElement, Microsoft.VisualStudio.QualityTools.Tips.UnitTest.ObjectModel, Version=10.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a" />
+      <TestLink id="842c8c3f-9ebf-2949-64e4-e118d925d64e" name="Test_Get_Root_Directory" storage="renci.sshnet.tests\bin\debug\renci.sshnet.tests.dll" type="Microsoft.VisualStudio.TestTools.TestTypes.Unit.UnitTestElement, Microsoft.VisualStudio.QualityTools.Tips.UnitTest.ObjectModel, Version=10.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a" />
+      <TestLink id="767acb2f-2b0c-2227-05ef-22178c779a33" name="Test_Sftp_Change_Directory" storage="renci.sshnet.tests\bin\debug\renci.sshnet.tests.dll" type="Microsoft.VisualStudio.TestTools.TestTypes.Unit.UnitTestElement, Microsoft.VisualStudio.QualityTools.Tips.UnitTest.ObjectModel, Version=10.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a" />
+      <TestLink id="d8cbe94f-d682-20ba-659f-a9c8986ae22d" name="Test_Sftp_ListDirectory_Permission_Denied" storage="renci.sshnet.tests\bin\debug\renci.sshnet.tests.dll" type="Microsoft.VisualStudio.TestTools.TestTypes.Unit.UnitTestElement, Microsoft.VisualStudio.QualityTools.Tips.UnitTest.ObjectModel, Version=10.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a" />
+      <TestLink id="e449ea7e-c991-cced-0a0e-dbb7043b0555" name="Test_Sftp_CreateDirectory_In_Current_Location" storage="renci.sshnet.tests\bin\debug\renci.sshnet.tests.dll" type="Microsoft.VisualStudio.TestTools.TestTypes.Unit.UnitTestElement, Microsoft.VisualStudio.QualityTools.Tips.UnitTest.ObjectModel, Version=10.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a" />
+      <TestLink id="ae8ea5fd-f0ba-9da5-2cdc-e0f47f3d5409" name="Test_Sftp_ListDirectory_HugeDirectory" storage="renci.sshnet.tests\bin\debug\renci.sshnet.tests.dll" type="Microsoft.VisualStudio.TestTools.TestTypes.Unit.UnitTestElement, Microsoft.VisualStudio.QualityTools.Tips.UnitTest.ObjectModel, Version=10.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a" />
+      <TestLink id="8595c9d0-7153-2141-b96d-b19c6e959b33" name="Test_Sftp_CreateDirectory_In_Forbidden_Directory" storage="renci.sshnet.tests\bin\debug\renci.sshnet.tests.dll" type="Microsoft.VisualStudio.TestTools.TestTypes.Unit.UnitTestElement, Microsoft.VisualStudio.QualityTools.Tips.UnitTest.ObjectModel, Version=10.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a" />
+      <TestLink id="1f0eddc0-c2b2-0aba-21ca-313cf8f09aa1" name="Test_Get_File" storage="renci.sshnet.tests\bin\debug\renci.sshnet.tests.dll" type="Microsoft.VisualStudio.TestTools.TestTypes.Unit.UnitTestElement, Microsoft.VisualStudio.QualityTools.Tips.UnitTest.ObjectModel, Version=10.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a" />
+      <TestLink id="ff23463d-d5d3-46bd-c184-e53689e9ef5d" name="Test_Sftp_DeleteDirectory" storage="renci.sshnet.tests\bin\debug\renci.sshnet.tests.dll" type="Microsoft.VisualStudio.TestTools.TestTypes.Unit.UnitTestElement, Microsoft.VisualStudio.QualityTools.Tips.UnitTest.ObjectModel, Version=10.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a" />
+      <TestLink id="1cae396c-6e6f-66d2-9f2b-2d35cfb6d8c5" name="Test_Sftp_Download_File_Not_Exists" storage="renci.sshnet.tests\bin\debug\renci.sshnet.tests.dll" type="Microsoft.VisualStudio.TestTools.TestTypes.Unit.UnitTestElement, Microsoft.VisualStudio.QualityTools.Tips.UnitTest.ObjectModel, Version=10.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a" />
+      <TestLink id="293683f6-5b0a-9c36-3360-95836ac13e3e" name="Test_Sftp_Rename_File" storage="renci.sshnet.tests\bin\debug\renci.sshnet.tests.dll" type="Microsoft.VisualStudio.TestTools.TestTypes.Unit.UnitTestElement, Microsoft.VisualStudio.QualityTools.Tips.UnitTest.ObjectModel, Version=10.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a" />
+      <TestLink id="aeeee14f-a9f7-aaeb-dca0-0f71f5d24bc1" name="Test_Sftp_Upload_And_Download_1MB_File" storage="renci.sshnet.tests\bin\debug\renci.sshnet.tests.dll" type="Microsoft.VisualStudio.TestTools.TestTypes.Unit.UnitTestElement, Microsoft.VisualStudio.QualityTools.Tips.UnitTest.ObjectModel, Version=10.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a" />
+      <TestLink id="86b4e210-a8c7-86d0-9b57-acd5d0060acb" name="Test_Sftp_CreateDirectory_Without_Connecting" storage="renci.sshnet.tests\bin\debug\renci.sshnet.tests.dll" type="Microsoft.VisualStudio.TestTools.TestTypes.Unit.UnitTestElement, Microsoft.VisualStudio.QualityTools.Tips.UnitTest.ObjectModel, Version=10.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a" />
+      <TestLink id="7ff3a089-3ed8-8531-8278-6044b9992b80" name="Test_Sftp_Download_Forbidden" storage="renci.sshnet.tests\bin\debug\renci.sshnet.tests.dll" type="Microsoft.VisualStudio.TestTools.TestTypes.Unit.UnitTestElement, Microsoft.VisualStudio.QualityTools.Tips.UnitTest.ObjectModel, Version=10.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a" />
+      <TestLink id="af3b3194-bfb2-9b70-efa0-27c4a025dd31" name="Test_Sftp_ListDirectory_Not_Exists" storage="renci.sshnet.tests\bin\debug\renci.sshnet.tests.dll" type="Microsoft.VisualStudio.TestTools.TestTypes.Unit.UnitTestElement, Microsoft.VisualStudio.QualityTools.Tips.UnitTest.ObjectModel, Version=10.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a" />
+      <TestLink id="d0f2ec5e-3aa1-2c25-4bcb-b7378f0d0283" name="Test_Sftp_Multiple_Async_Upload_And_Download_10Files_5MB_Each" storage="renci.sshnet.tests\bin\debug\renci.sshnet.tests.dll" type="Microsoft.VisualStudio.TestTools.TestTypes.Unit.UnitTestElement, Microsoft.VisualStudio.QualityTools.Tips.UnitTest.ObjectModel, Version=10.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a" />
+      <TestLink id="d8eea890-99df-9b9f-7083-3a306dd65565" name="Test_Sftp_CreateDirectory_Invalid_Path" storage="renci.sshnet.tests\bin\debug\renci.sshnet.tests.dll" type="Microsoft.VisualStudio.TestTools.TestTypes.Unit.UnitTestElement, Microsoft.VisualStudio.QualityTools.Tips.UnitTest.ObjectModel, Version=10.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a" />
+      <TestLink id="dde422f9-1b3b-0885-224c-b2c1a67b82dc" name="Test_Sftp_Upload_Forbidden" storage="renci.sshnet.tests\bin\debug\renci.sshnet.tests.dll" type="Microsoft.VisualStudio.TestTools.TestTypes.Unit.UnitTestElement, Microsoft.VisualStudio.QualityTools.Tips.UnitTest.ObjectModel, Version=10.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a" />
+    </TestLinks>
+  </TestList>
+  <TestList name="Lists of Tests" id="8c43106b-9dc1-4907-a29f-aa66a61bf5b6" />
+</TestLists>