A Metamask fork with Infura removed and default networks editable
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 
 
 
ciphermask/test/unit/reducers/unlock_vault_test.js

35 lines
1.0 KiB

import assert from 'assert'
import * as actions from '../../../ui/app/store/actions'
import reducers from '../../../ui/app/ducks'
describe('#unlockMetamask(selectedAccount)', function () {
describe('after an error', function () {
it('clears warning', function () {
const warning = 'this is the wrong warning'
const account = 'foo_account'
const initialState = {
appState: {
warning: warning,
},
}
const resultState = reducers(initialState, actions.unlockMetamask(account))
assert.equal(resultState.appState.warning, null, 'warning nullified')
})
})
describe('going home after an error', function () {
it('clears warning', function () {
const warning = 'this is the wrong warning'
// const account = 'foo_account'
const initialState = {
appState: {
warning: warning,
},
}
const resultState = reducers(initialState, actions.goHome())
assert.equal(resultState.appState.warning, null, 'warning nullified')
})
})
})