예제 #1
0
        public void Constructor_SetsName()
        {
            const string expectedName = "Service";
            var          imposter     = new SmtpImposter(123, expectedName);

            Assert.AreEqual(expectedName, imposter.Name);
        }
예제 #2
0
        public void Constructor_SetsPort()
        {
            const int port     = 123;
            var       imposter = new SmtpImposter(port, null);

            Assert.AreEqual(port, imposter.Port);
        }
예제 #3
0
        public void Constructor_AllowsNullPort()
        {
            var imposter = new SmtpImposter(null, null);

            Assert.AreEqual(default(int), imposter.Port);
        }
예제 #4
0
        public void Constructor_SetsProtocol()
        {
            var imposter = new SmtpImposter(123, null);

            Assert.AreEqual("smtp", imposter.Protocol);
        }