Open a wallet by file name.
function openWallet(filename) {
  try {
    // Delete the cached copy of the wallet. This allows testing of list-wallets.
    delete require.cache[require.resolve(filename)]

    const walletInfo = require(filename)
    return walletInfo
  } catch (err) {
    throw new Error(`Could not open ${filename}`)
  }
}