Replace OP_EVAL (BIP 12) with Pay-to-script-hash (BIP 16).
[novacoin.git] / src / test / test_bitcoin.cpp
index 4b52b74..7ff7545 100644 (file)
@@ -4,18 +4,24 @@
 #include "main.h"
 #include "wallet.h"
 
+CWallet* pwalletMain;
+
 extern bool fPrintToConsole;
 struct TestingSetup {
     TestingSetup() {
         fPrintToConsole = true; // don't want to write to debug.log file
+        pwalletMain = new CWallet();
+        RegisterWallet(pwalletMain);
+    }
+    ~TestingSetup()
+    {
+        delete pwalletMain;
+        pwalletMain = NULL;
     }
-    ~TestingSetup() { }
 };
 
 BOOST_GLOBAL_FIXTURE(TestingSetup);
 
-CWallet* pwalletMain;
-
 void Shutdown(void* parg)
 {
   exit(0);