Example #1
0
        public void CanEvaluateChallenge()
        {
            Hashtable   props  = new Hashtable();
            ISaslClient client = new AnonymousSaslClient(AUTHID, props, this);

            Assert.IsFalse(client.IsComplete);
            byte[] response = client.EvaluateChallenge(new byte[0]);
            Assert.AreEqual(AUTHID, Encoding.UTF8.GetString(response));

            Assert.IsTrue(client.IsComplete);
        }
Example #2
0
        public void HasInitialResponseReturnsTrue()
        {
            ISaslClient client = new AnonymousSaslClient(AUTHID, new Hashtable(), this);

            Assert.IsTrue(client.HasInitialResponse);
        }
Example #3
0
        public void ReturnsRightMechanismName()
        {
            ISaslClient client = new AnonymousSaslClient(AUTHID, new Hashtable(), this);

            Assert.AreEqual("ANONYMOUS", client.MechanismName);
        }