2
0

SshConnectionExceptionTest.cs 3.0 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879
  1. using System;
  2. using System.Runtime.Serialization;
  3. using Microsoft.VisualStudio.TestTools.UnitTesting;
  4. using Renci.SshNet.Common;
  5. using Renci.SshNet.Messages.Transport;
  6. using Renci.SshNet.Tests.Common;
  7. namespace Renci.SshNet.Tests.Classes.Common
  8. {
  9. /// <summary>
  10. ///This is a test class for SshConnectionExceptionTest and is intended
  11. ///to contain all SshConnectionExceptionTest Unit Tests
  12. ///</summary>
  13. [TestClass]
  14. public class SshConnectionExceptionTest : TestBase
  15. {
  16. /// <summary>
  17. ///A test for SshConnectionException Constructor
  18. ///</summary>
  19. [TestMethod]
  20. public void SshConnectionExceptionConstructorTest()
  21. {
  22. var target = new SshConnectionException();
  23. Assert.Inconclusive("TODO: Implement code to verify target");
  24. }
  25. /// <summary>
  26. ///A test for SshConnectionException Constructor
  27. ///</summary>
  28. [TestMethod]
  29. public void SshConnectionExceptionConstructorTest1()
  30. {
  31. var message = string.Empty; // TODO: Initialize to an appropriate value
  32. var target = new SshConnectionException(message);
  33. Assert.Inconclusive("TODO: Implement code to verify target");
  34. }
  35. /// <summary>
  36. ///A test for SshConnectionException Constructor
  37. ///</summary>
  38. [TestMethod]
  39. public void SshConnectionExceptionConstructorTest2()
  40. {
  41. var message = string.Empty; // TODO: Initialize to an appropriate value
  42. var disconnectReasonCode = new DisconnectReason(); // TODO: Initialize to an appropriate value
  43. var target = new SshConnectionException(message, disconnectReasonCode);
  44. Assert.Inconclusive("TODO: Implement code to verify target");
  45. }
  46. /// <summary>
  47. ///A test for SshConnectionException Constructor
  48. ///</summary>
  49. [TestMethod]
  50. public void SshConnectionExceptionConstructorTest3()
  51. {
  52. var message = string.Empty; // TODO: Initialize to an appropriate value
  53. var disconnectReasonCode = new DisconnectReason(); // TODO: Initialize to an appropriate value
  54. Exception inner = null; // TODO: Initialize to an appropriate value
  55. var target = new SshConnectionException(message, disconnectReasonCode, inner);
  56. Assert.Inconclusive("TODO: Implement code to verify target");
  57. }
  58. /// <summary>
  59. ///A test for GetObjectData
  60. ///</summary>
  61. [TestMethod]
  62. [Ignore] // placeholder for actual test
  63. public void GetObjectDataTest()
  64. {
  65. var target = new SshConnectionException(); // TODO: Initialize to an appropriate value
  66. SerializationInfo info = null; // TODO: Initialize to an appropriate value
  67. var context = new StreamingContext(); // TODO: Initialize to an appropriate value
  68. target.GetObjectData(info, context);
  69. Assert.Inconclusive("A method that does not return a value cannot be verified.");
  70. }
  71. }
  72. }