2
0

SftpClientTest.DeleteFileAsync.cs 691 B

12345678910111213141516171819202122232425
  1. using System;
  2. using System.Threading.Tasks;
  3. using Microsoft.VisualStudio.TestTools.UnitTesting;
  4. using Renci.SshNet.Tests.Properties;
  5. namespace Renci.SshNet.Tests.Classes
  6. {
  7. /// <summary>
  8. /// Implementation of the SSH File Transfer Protocol (SFTP) over SSH.
  9. /// </summary>
  10. public partial class SftpClientTest
  11. {
  12. [TestMethod]
  13. [ExpectedException(typeof(ArgumentNullException))]
  14. public async Task Test_Sftp_DeleteFileAsync_Null()
  15. {
  16. using (var sftp = new SftpClient(Resources.HOST, Resources.USERNAME, Resources.PASSWORD))
  17. {
  18. await sftp.DeleteFileAsync(null, default);
  19. }
  20. }
  21. }
  22. }