diff --git a/test/html_pipeline_test.rb b/test/html_pipeline_test.rb index 4a797d27..c88cce4c 100644 --- a/test/html_pipeline_test.rb +++ b/test/html_pipeline_test.rb @@ -194,4 +194,19 @@ def test_node_filter_instance_context_is_carried_over_in_call # - mentions are linked assert_equal("

yeH! I think @gjtorikian is great!

", result) end + + def test_mention_and_team_mention_node_filters_are_applied + text = "Hey there, @billy. This one goes out to the @cool/dev team!" + + pipeline = HTMLPipeline.new( + convert_filter: HTMLPipeline::ConvertFilter::MarkdownFilter.new, + node_filters: [ + HTMLPipeline::NodeFilter::MentionFilter.new, + HTMLPipeline::NodeFilter::TeamMentionFilter.new + ], + ) + result = pipeline.call(text)[:output] + + assert_equal("

Hey there, @billy. This one goes out to the @cool/dev team!

", result) + end end