예제 #1
0
        public void GetTest()
        {
            string url  = "https://www.baidu.com/s?ie=UTF-8&wd=c%23";
            string html = RestSharpManager.Get(url);

            Assert.True(html != null);
        }
예제 #2
0
        public void GetTest2()
        {
            // 等同于 https://www.baidu.com/s?ie=UTF-8&wd=c%23
            string url  = "https://www.baidu.com/s";
            string html = RestSharpManager.Get(url, null, null, null, new Dictionary <string, object> {
                { "ie", "UTF-8" }, { "wd", "c#" }
            });

            Assert.True(html != null);
        }