From 88355cb41deadcc35f49179ea45fb8cde8c2c3ed Mon Sep 17 00:00:00 2001 From: Will Hunt <will@half-shot.uk> Date: Thu, 7 Jun 2018 12:21:30 +0100 Subject: [PATCH] And subdomain tests too --- test/test_matrixeventprocessor.ts | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/test/test_matrixeventprocessor.ts b/test/test_matrixeventprocessor.ts index fb60f4c..01572ec 100644 --- a/test/test_matrixeventprocessor.ts +++ b/test/test_matrixeventprocessor.ts @@ -266,6 +266,10 @@ describe("MatrixEventProcessor", () => { processor.FindMentionsInPlainBody("I really love going to https://TestUsername.com", members), "I really love going to https://TestUsername.com", ); + Chai.assert.equal( + processor.FindMentionsInPlainBody("I really love going to www.TestUsername.com", members), + "I really love going to www.TestUsername.com", + ); }); it("processes mentioned nickname correctly", async () => { const processor = createMatrixEventProcessor(); @@ -318,6 +322,10 @@ describe("MatrixEventProcessor", () => { processor.FindMentionsInPlainBody("I really love going to https://Test.com", members), "I really love going to https://Test.com", ); + Chai.assert.equal( + processor.FindMentionsInPlainBody("I really love going to www.Test.com", members), + "I really love going to www.Test.com", + ); }); it("processes non-mentions correctly", async () => { const processor = createMatrixEventProcessor(); -- GitLab