fixed error in test project

This commit is contained in:
David Sparer
2017-08-06 10:40:36 -05:00
parent b4c535c76a
commit 1a7ce13ec3

View File

@@ -3,7 +3,6 @@ using mRemoteNG.Credential;
using NSubstitute; using NSubstitute;
using NUnit.Framework; using NUnit.Framework;
namespace mRemoteNGTests.Credential namespace mRemoteNGTests.Credential
{ {
public class CredentialDeletionMsgBoxConfirmerTests public class CredentialDeletionMsgBoxConfirmerTests
@@ -20,14 +19,14 @@ namespace mRemoteNGTests.Credential
public void ClickingYesReturnsTrue() public void ClickingYesReturnsTrue()
{ {
var deletionConfirmer = new CredentialDeletionMsgBoxConfirmer(MockClickYes); var deletionConfirmer = new CredentialDeletionMsgBoxConfirmer(MockClickYes);
Assert.That(deletionConfirmer.Confirm(_credentialRecord), Is.True); Assert.That(deletionConfirmer.Confirm(new[] { _credentialRecord }), Is.True);
} }
[Test] [Test]
public void ClickingNoReturnsFalse() public void ClickingNoReturnsFalse()
{ {
var deletionConfirmer = new CredentialDeletionMsgBoxConfirmer(MockClickNo); var deletionConfirmer = new CredentialDeletionMsgBoxConfirmer(MockClickNo);
Assert.That(deletionConfirmer.Confirm(_credentialRecord), Is.False); Assert.That(deletionConfirmer.Confirm(new [] { _credentialRecord }), Is.False);
} }
private DialogResult MockClickYes(string promptMessage, string title, MessageBoxButtons buttons, MessageBoxIcon icon) private DialogResult MockClickYes(string promptMessage, string title, MessageBoxButtons buttons, MessageBoxIcon icon)
@@ -40,4 +39,4 @@ namespace mRemoteNGTests.Credential
return DialogResult.No; return DialogResult.No;
} }
} }
} }