Beispiel #1
0
        public void CreateQueryString_Null_NotAutoAppend_Should_Ok()
        {
            var simpleQueryString = new SimpleQueryString();
            var queryString       = simpleQueryString.CreateQueryString(null, false);

            queryString.ShouldEqual(string.Empty);
        }
Beispiel #2
0
        public void CreateQueryString_EmptyValue_Should_Ok()
        {
            var simpleQueryString = new SimpleQueryString();
            var nvc = new NameValueCollection();

            nvc.Add("a", "1");
            nvc.Add("b", "");
            var queryString = simpleQueryString.CreateQueryString(nvc, false);

            queryString.ShouldEqual("a=1&b=");
        }