public void AddSharedWebCredentialNullAccount() { account = null; Action <NSError> handler = (NSError e) => { }; Assert.Throws <ArgumentNullException> (() => SecSharedCredential.AddSharedWebCredential(domainName, account, password, handler)); }
public void CreateSharedWebCredentialPassword() { TestRuntime.AssertSystemVersion(ApplePlatform.iOS, 8, 0, throwIfOtherPlatform: false); var pwd = SecSharedCredential.CreateSharedWebCredentialPassword(); Assert.IsNotNull(pwd); }
public void AddSharedWebCredentialNotNullPassword() { TestRuntime.AssertSystemVersion(ApplePlatform.iOS, 8, 0, throwIfOtherPlatform: false); Action <NSError> handler = (NSError e) => { // we do nothing, if we did block the test should be interactive because a dialog is shown. }; SecSharedCredential.AddSharedWebCredential(domainName, account, password, handler); }
public void CreateSharedWebCredentialPassword() { if (!TestRuntime.CheckSystemAndSDKVersion(8, 0)) { Assert.Ignore("Ignoring CreateSharedWebCredentialPassword test: Requires iOS8+"); } var pwd = SecSharedCredential.CreateSharedWebCredentialPassword(); Assert.IsNotNull(pwd); }
public void AddSharedWebCredentialNullAccount() { account = null; Action <NSError> handler = (NSError e) => { Assert.IsNull(e); waitEvent.Set(); }; SecSharedCredential.AddSharedWebCredential(domainName, account, password, handler); waitEvent.WaitOne(); Assert.Pass("Block was correctly executed."); }
public void AddSharedWebCredentialNotNullPassword() { if (!TestRuntime.CheckSystemAndSDKVersion(8, 0)) { Assert.Ignore("Ignoring AddSharedWebCredentialNotNullPassword test: Requires iOS8+"); } Action <NSError> handler = (NSError e) => { // we do nothing, if we did block the test should be interactive because a dialog is shown. }; SecSharedCredential.AddSharedWebCredential(domainName, account, password, handler); }
public void RequestSharedWebCredentialNullAccount() { if (!TestRuntime.CheckSystemAndSDKVersion(8, 0)) { Assert.Ignore("Ignoring RequestSharedWebCredentialNullAccount test: Requires iOS8+"); } Action <string[], NSError> getHandler = (string [] pwds, NSError e) => { waitEvent.Set(); }; SecSharedCredential.RequestSharedWebCredential(null, null, getHandler); waitEvent.WaitOne(); Assert.Pass("Block was correctly executed."); }