示例#1
0
        public virtual void TestWepAppContextAfterServerStop()
        {
            HttpServer2 server = null;
            string      key    = "test.attribute.key";
            string      value  = "test.attribute.value";

            server = CreateTestServer();
            AssertNotLive(server);
            server.Start();
            server.SetAttribute(key, value);
            AssertAlive(server);
            Assert.Equal(value, server.GetAttribute(key));
            Stop(server);
            NUnit.Framework.Assert.IsNull("Server context should have cleared", server.GetAttribute
                                              (key));
        }