1
0
mirror of https://github.com/kremalicious/metamask-extension.git synced 2024-11-23 18:41:38 +01:00
metamask-extension/test/lib/shallow-with-store.js

17 lines
346 B
JavaScript
Raw Normal View History

2017-11-26 01:37:12 +01:00
const { shallow, mount } = require('enzyme')
2017-11-02 18:28:41 +01:00
2017-11-26 01:37:12 +01:00
exports.shallowWithStore = function shallowWithStore (component, store) {
2017-11-02 18:28:41 +01:00
const context = {
store,
}
return shallow(component, { context })
2017-11-26 01:37:12 +01:00
}
exports.mountWithStore = function mountWithStore (component, store) {
const context = {
store,
}
return mount(component, { context })
}