diff --git a/test/components/Form/Payform.spec.js b/test/components/Form/Payform.spec.js index 7ce28039..740ea4b1 100644 --- a/test/components/Form/Payform.spec.js +++ b/test/components/Form/Payform.spec.js @@ -38,4 +38,26 @@ describe('Form', () => { expect(el.contains('on-chain')).toBe(false) }) }) + + describe('should show lightning with a lightning input', () => { + const props = { ...defaultProps, isLn: true } + const el = shallow() + + it('should contain PayForm', () => { + expect(el.find('input#paymentRequest').props.value).toBe(undefined) + expect(el.contains('lightning network')).toBe(true) + expect(el.contains('on-chain')).toBe(false) + }) + }) + + describe('should show on-chain with an on-chain input', () => { + const props = { ...defaultProps, isOnchain: true } + const el = shallow() + + it('should contain PayForm', () => { + expect(el.find('input#paymentRequest').props.value).toBe(undefined) + expect(el.contains('lightning network')).toBe(false) + expect(el.contains('on-chain')).toBe(true) + }) + }) })