コード例 #1
0
        public void GeoTrackerClientSettings_ConfigDefault()
        {
            try
            {
                Config.SetConfig(string.Empty);

                var settings = GeoTrackerClientSettings.LoadConfig("Test");

                Assert.AreEqual("logical://LillTek/GeoTracker/Server", settings.ServerEP);
            }
            finally
            {
                Config.SetConfig(null);
            }
        }
コード例 #2
0
        public void GeoTrackerClientSettings_ConfigSettings()
        {
            string cfg = @"
&section Test

    ServerEP = logical://foo/bar

&endsection
";

            try
            {
                Config.SetConfig(cfg.Replace('&', '#'));

                var settings = GeoTrackerClientSettings.LoadConfig("Test");

                Assert.AreEqual("logical://foo/bar", settings.ServerEP);
            }
            finally
            {
                Config.SetConfig(null);
            }
        }