Ejemplo n.º 1
0
        public static void Delete(object[] objs)
        {
            int length = objs.Length;

            for (int i = 0; i < length; ++i)
            {
                objs[i] = null;
            }

            current.Delete(objs);
        }
Ejemplo n.º 2
0
        public void CreatePoolWithValidGenesisFile()
        {
            string file = PoolUtils.GenerateGenesisFile();

            IPool pool = Factory.GetPool("CreatePool", file);

            pool.Create();

            Assert.IsTrue(System.IO.File.Exists(file), "expected to find genesis file created.");

            pool.Delete();
        }
Ejemplo n.º 3
0
        public void ListPoolTest()
        {
            string file = PoolUtils.GenerateGenesisFile();

            IPool pool = Factory.GetPool("ListPool", file);

            pool.Create();

            List <IPool> pools = Factory.ListPools();

            Assert.IsNotNull(pools);
            pool.Delete();

            Assert.IsTrue(0 < pools.Count, "expected to find at least one pool");
        }
Ejemplo n.º 4
0
        public void Cleanup()
        {
            try
            {
                _wallet.Close();
                _wallet.Delete();
                _wallet = null;

                _pool.Close();
                _pool.Delete();
                _pool = null;

                foreach (string fileName in _filesCreated)
                {
                    System.IO.File.Delete(fileName);
                }
            }
            catch (Exception ex)
            {
                Logger.Warn($"WriteDidAndQueryVeryKeyDemo failed to cleanup {ex.Message}");
            }
        }
Ejemplo n.º 5
0
        public void Cleanup()
        {
            try
            {
                _wallet.Close();
                _wallet.Delete();
                _wallet = null;

                _pool.Close();
                _pool.Delete();
                _pool = null;

                foreach (string fileName in _filesCreated)
                {
                    System.IO.File.Delete(fileName);
                }
            }
            catch (Exception ex)
            {
                Logger.Warn($"AllPaymentDotNetPayTests failed to cleanup {ex.Message}");
            }
        }