private void DeletePreviousData(string path)
        {
            Stat stat = ZkActions.Exists(path, false);

            if (stat != null)
            {
                ZkActions.Delete(path, stat.Version);
            }
        }
        public void ZNodeShouldBeDeletedWhenDeleting()
        {
            string path = "/TestDelete";

            DeletePreviousData(path);
            Stat stat = CreateNodeWithdata(path, "Test Delete");

            byte[] returnedRawData = ZkActions.GetData(path, false, stat);
            Assert.AreEqual("Test Delete", TextConvertor.GetSTextFromBytesAscii(returnedRawData));
            ZkActions.Delete(path, stat.Version);
        }