X-Git-Url: https://git.immae.eu/?a=blobdiff_plain;f=server%2Ftests%2Fhelpers%2Fmarkdown.ts;h=6fab31d6f04d57c04aafd0b0d4ca373b5ba283bd;hb=6e06694fd6acab185432bccf57bd5c9c3b68f218;hp=0488a1a055293c74af1268055da7142f8ea9f6e4;hpb=c68e2b2d223c57836e04e18105255cf0e10ae75b;p=github%2FChocobozzz%2FPeerTube.git diff --git a/server/tests/helpers/markdown.ts b/server/tests/helpers/markdown.ts index 0488a1a05..6fab31d6f 100644 --- a/server/tests/helpers/markdown.ts +++ b/server/tests/helpers/markdown.ts @@ -1,6 +1,5 @@ /* eslint-disable @typescript-eslint/no-unused-expressions,@typescript-eslint/require-await */ -import 'mocha' import { mdToOneLinePlainText } from '@server/helpers/markdown' import { expect } from 'chai' @@ -30,5 +29,11 @@ describe('Markdown helpers', function () { expect(result).to.equal('Hello coucou') }) + + it('Should convert tags to plain text', function () { + const result = mdToOneLinePlainText(`#déconversion\n#newage\n#histoire`) + + expect(result).to.equal('#déconversion #newage #histoire') + }) }) })