aboutsummaryrefslogtreecommitdiffstats
path: root/ui/app/pages/send/send-content/send-from-row/tests/send-from-row-container.test.js
blob: fd771ea775fe05a8fa82585fc74461c8e6354801 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
import assert from 'assert'
import proxyquire from 'proxyquire'

let mapStateToProps

proxyquire('../send-from-row.container.js', {
  'react-redux': {
    connect: ms => {
      mapStateToProps = ms
      return () => ({})
    },
  },
  '../../send.selectors.js': {
    getSendFromObject: (s) => `mockFrom:${s}`,
  },
})

describe('send-from-row container', () => {
  describe('mapStateToProps()', () => {
    it('should map the correct properties to props', () => {
      assert.deepEqual(mapStateToProps('mockState'), {
        from: 'mockFrom:mockState',
      })
    })
  })
})