1 | import React from 'react'
|
2 | import 'jest-styled-components'
|
3 |
|
4 | import { ReferralSection } from 'SRC'
|
5 |
|
6 | const { shallowWithTheme } = global
|
7 |
|
8 | describe('(Styled Component) ReferralSection', () => {
|
9 | const createReferralSection = (props) => {
|
10 | return shallowWithTheme(<ReferralSection {...props} />)
|
11 | }
|
12 |
|
13 | test('matching the snapshot', () => {
|
14 | expect(createReferralSection({
|
15 | referralValue: '20',
|
16 | homepageUrl: 'https://localhost:3001',
|
17 | referralClicked: () => {},
|
18 | referralCode: 'referral1234',
|
19 | name: 'John Doe'
|
20 | }))
|
21 | .toMatchSnapshot()
|
22 | })
|
23 | })
|
24 |
|
\ | No newline at end of file |