diff options
author | Harrison Healey <harrisonmhealey@gmail.com> | 2017-09-05 12:39:07 -0400 |
---|---|---|
committer | Saturnino Abril <saturnino.abril@gmail.com> | 2017-09-06 00:39:07 +0800 |
commit | 575864c917dbbe6b58d3e4534c3015327f2cb088 (patch) | |
tree | 547ecd46393b82961e4e5518d47273d8bb4ed2f6 /app/notification_test.go | |
parent | daed8ffbf6151f01866b9299574fdf6764c8b7bd (diff) | |
download | chat-575864c917dbbe6b58d3e4534c3015327f2cb088.tar.gz chat-575864c917dbbe6b58d3e4534c3015327f2cb088.tar.bz2 chat-575864c917dbbe6b58d3e4534c3015327f2cb088.zip |
PLT-7474 Stopped requiring confirmation for mentions in code blocks (#7375)
* PLT-7474 Stopped requiring confirmation for mentions in code blocks
* Stopped mentioning people from code blocks using ~~~
Diffstat (limited to 'app/notification_test.go')
-rw-r--r-- | app/notification_test.go | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/app/notification_test.go b/app/notification_test.go index 02b6e1db0..e0c1a54e6 100644 --- a/app/notification_test.go +++ b/app/notification_test.go @@ -399,6 +399,12 @@ func TestRemoveCodeFromMessage(t *testing.T) { if actual := removeCodeFromMessage(input); actual != expected { t.Fatalf("received incorrect output\n\nGot:\n%v\n\nExpected:\n%v\n", actual, expected) } + + input = "this is text with\n~~~\na code block\n~~~\nin it" + expected = "this is text with\n\nin it" + if actual := removeCodeFromMessage(input); actual != expected { + t.Fatalf("received incorrect output\n\nGot:\n%v\n\nExpected:\n%v\n", actual, expected) + } } func TestGetMentionKeywords(t *testing.T) { |