コード例 #1
0
ファイル: SharpBossTest.cs プロジェクト: racerxdl/AppServer
        public void TestDefaultListenUrl()
        {
            this._sharpBoss = new SharpBoss();

            Assert.NotNull(this._sharpBoss);
            Assert.NotNull(this._sharpBoss.GetHttpServerListenUrl());
        }
コード例 #2
0
ファイル: SharpBossTest.cs プロジェクト: racerxdl/AppServer
        public void TestListenUrlWithoutSlash()
        {
            var listenUrl = "http://localhost:4321";

            this._sharpBoss = new SharpBoss(listenUrl);

            Assert.NotNull(this._sharpBoss);
            Assert.AreEqual(listenUrl + "/", this._sharpBoss.GetHttpServerListenUrl());
        }
コード例 #3
0
        public void Setup()
        {
            (this._app, this._assembly) = WebServerFixture.CreateNewServer();
            var listenUrl = "http://localhost:4550";

            this._sharpBoss = new SharpBoss(listenUrl);
            this._sharpBoss.Run();
            this._client = new RestClient(listenUrl);
        }
コード例 #4
0
ファイル: SharpBossTest.cs プロジェクト: racerxdl/AppServer
        public void TestListenUrlFromConfigWithoutSlash()
        {
            var listenUrl   = "http://localhost:2122";
            var appSettings = WebServerFixture.CreateConfigFile(listenUrl);

            this._sharpBoss = new SharpBoss(appSettings: appSettings);

            Assert.NotNull(this._sharpBoss);
            Assert.AreEqual(listenUrl + "/", this._sharpBoss.GetHttpServerListenUrl());
        }
コード例 #5
0
ファイル: SharpBossTest.cs プロジェクト: racerxdl/AppServer
        public void TestListenUrlFromEnvironmentWithoutSlash()
        {
            var listenUrl = "http://localhost:3145";

            Environment.SetEnvironmentVariable("SHARPBOSS_URL", listenUrl);

            this._sharpBoss = new SharpBoss();

            Assert.NotNull(this._sharpBoss);
            Assert.AreEqual(listenUrl + "/", this._sharpBoss.GetHttpServerListenUrl());
        }