aboutsummaryrefslogtreecommitdiff
path: root/test
diff options
context:
space:
mode:
authorHenry Jameson <me@hjkos.com>2021-06-18 21:29:47 +0300
committerHenry Jameson <me@hjkos.com>2021-06-18 21:29:47 +0300
commit8fe4355a6b84ae81b54228e6749a4ab82966ff2e (patch)
treebbfd77cae3f9472c9758c7b166c524cfd37fe117 /test
parentb68fb7738ba0721183d4910aecce1ac741692734 (diff)
fix rich images
Diffstat (limited to 'test')
-rw-r--r--test/unit/specs/services/html_converter/html_line_converter.spec.js7
1 files changed, 7 insertions, 0 deletions
diff --git a/test/unit/specs/services/html_converter/html_line_converter.spec.js b/test/unit/specs/services/html_converter/html_line_converter.spec.js
index de7c7fc2..86bd7e8b 100644
--- a/test/unit/specs/services/html_converter/html_line_converter.spec.js
+++ b/test/unit/specs/services/html_converter/html_line_converter.spec.js
@@ -69,6 +69,13 @@ describe('html_line_converter', () => {
const comparableResult = result.map(mapOnlyText(processorKeep)).join('')
expect(comparableResult).to.eql(inputOutput)
})
+
+ it('fed with some recognized but not handled elements', () => {
+ const inputOutput = 'testing images\n\n<img src="benis.png">'
+ const result = convertHtmlToLines(inputOutput)
+ const comparableResult = result.map(mapOnlyText(processorKeep)).join('')
+ expect(comparableResult).to.eql(inputOutput)
+ })
})
describe('with processor that replaces lines with word "_" should match expected line when', () => {
const processorReplace = (line) => '_'