From e8401a188445d4ea1d2b5aa1aff2b97829737e00 Mon Sep 17 00:00:00 2001 From: Dani Pinyol Date: Mon, 7 Dec 2020 14:35:25 +0100 Subject: [PATCH] test(react): Text with
with & without markdown --- .../__snapshots__/text.test.jsx.snap | 26 +++++++++++++++++++ .../tests/components/text.test.jsx | 24 +++++++++++++++++ 2 files changed, 50 insertions(+) diff --git a/packages/botonic-react/tests/components/__snapshots__/text.test.jsx.snap b/packages/botonic-react/tests/components/__snapshots__/text.test.jsx.snap index c946dcf2d4..2f6c025e7e 100644 --- a/packages/botonic-react/tests/components/__snapshots__/text.test.jsx.snap +++ b/packages/botonic-react/tests/components/__snapshots__/text.test.jsx.snap @@ -81,6 +81,32 @@ Array [ ] `; +exports[`Text Component Text with
: markdown disabled 1`] = ` + + hi +
+ bye +
+`; + +exports[`Text Component Text with
: markdown enabled 1`] = ` + + hi + <br> + bye + +`; + exports[`Text Component Text with 1 button 1`] = ` { expect(tree).toMatchSnapshot() }) + test('Text with
: markdown disabled', () => { + const sut = ( + + hi +
+ bye +
+ ) + const tree = renderToJSON(sut) + expect(tree).toMatchSnapshot() + }) + + test('Text with
: markdown enabled', () => { + const sut = ( + + hi +
+ bye +
+ ) + const tree = renderToJSON(sut) + expect(tree).toMatchSnapshot() + }) + test('Text with 1 button', () => { const sut = (