public void TestDocUpdate()
        {
            var target = new CloudsearchDoc(ApplicationName, api);

            var data = "[{\"fields\":{\"a\":\"1\",\"b\":\"test\"},\"cmd\":\"UPDATE\"}]";

            target.Add(data);
            var result = target.Push("es_journal");

            Assert.AreEqual("OK", result.Status);
        }
        public void TestDocAdd1()
        {
            var target = new CloudsearchDoc(ApplicationName, api); // TODO: 初始化为适当的值

            var data = "[{\"a\":\"1\"}]";

            target.Add(data);
            var result = target.Push("main");

            Console.WriteLine(result);

            Assert.AreEqual("OK", result.Status);
            //Assert.AreEqual(expected, actual);
            //Assert.Inconclusive("验证此测试方法的正确性。");
        }
        public void TestDocAdd()
        {
            var target = new CloudsearchDoc(ApplicationName, api); // TODO: 初始化为适当的值
            var pk     = RandomStr(5);
            var data   = "[{\"id\":\"" + pk + "\"}]";

            target.Add(data);
            var result = target.Push("es_journal");

            Console.WriteLine(result);
            Console.WriteLine(pk);

            Assert.AreEqual("OK", result.Status);
            //Assert.AreEqual(expected, actual);
            //Assert.Inconclusive("验证此测试方法的正确性。");
        }