Browse Source

follow-up of prev commit: fix travis build

seed_v14
SomberNight 7 years ago
parent
commit
3fe2af242e
  1. 14
      lib/tests/test_storage_upgrade.py

14
lib/tests/test_storage_upgrade.py

@ -1,3 +1,6 @@
import shutil
import tempfile
from lib.storage import WalletStorage
from lib.wallet import Wallet
@ -241,13 +244,22 @@ class TestStorageUpgrade(WalletTestCase):
@classmethod
def setUpClass(cls):
super().setUpClass()
from lib.plugins import Plugins
from lib.simple_config import SimpleConfig
config = SimpleConfig()
cls.electrum_path = tempfile.mkdtemp()
config = SimpleConfig({'electrum_path': cls.electrum_path})
gui_name = 'qt'
# TODO it's probably wasteful to load all plugins... only need Trezor
Plugins(config, True, gui_name)
@classmethod
def tearDownClass(cls):
super().tearDownClass()
shutil.rmtree(cls.electrum_path)
def _upgrade_storage(self, wallet_json, accounts=1):
storage = self._load_storage_from_json_string(wallet_json, manual_upgrades=True)

Loading…
Cancel
Save