aboutsummaryrefslogblamecommitdiffstats
path: root/test/lib/shallow-with-store.js
blob: 9df10a3c5097e7bcf4e88cb5fd91bc2ebd548c08 (plain) (tree)
1
2
3
4
5
6
7
8
                                            
 





                                              


                   
                                      

 
                                            


                   
                                    
 
const { shallow, mount } = require('enzyme')

module.exports = {
  shallowWithStore,
  mountWithStore,
}

function shallowWithStore (component, store) {
  const context = {
    store,
  }
  return shallow(component, {context})
}

function mountWithStore (component, store) {
  const context = {
    store,
  }
  return mount(component, {context})
}