summaryrefslogtreecommitdiff
path: root/spec/fixtures
diff options
context:
space:
mode:
authorRobert Speicher <rspeicher@gmail.com>2015-05-27 15:39:08 -0400
committerRobert Speicher <rspeicher@gmail.com>2015-05-27 15:39:08 -0400
commit7424d2fa5bd52b7f41ec4359bf80b1649b59706b (patch)
treecef2d5cecb4f2682de18eb379e4bea0d76087239 /spec/fixtures
parentc843e092f309d22281205e34658221f17642ea33 (diff)
downloadgitlab-ce-7424d2fa5bd52b7f41ec4359bf80b1649b59706b.tar.gz
Add ExternalLinkFilter to Markdown pipeliners-dont-follow-me
Forces a `rel="nofollow"` attribute on all external links.
Diffstat (limited to 'spec/fixtures')
-rw-r--r--spec/fixtures/markdown.md.erb9
1 files changed, 8 insertions, 1 deletions
diff --git a/spec/fixtures/markdown.md.erb b/spec/fixtures/markdown.md.erb
index 26fc4e38e5a..02ab46c905a 100644
--- a/spec/fixtures/markdown.md.erb
+++ b/spec/fixtures/markdown.md.erb
@@ -79,7 +79,7 @@ As permissive as it is, we've allowed even more stuff:
<span>span tag</span>
-<a href="#" rel="nofollow">This is a link with a defined rel attribute, which should be removed</a>
+<a href="#" rel="bookmark">This is a link with a defined rel attribute, which should be removed</a>
<a href="javascript:alert('Hi')">This is a link trying to be sneaky. It gets its link removed entirely.</a>
@@ -127,6 +127,13 @@ But it shouldn't autolink text inside certain tags:
- <a>http://about.gitlab.com/</a>
- <kbd>http://about.gitlab.com/</kbd>
+### ExternalLinkFilter
+
+External links get a `rel="nofollow"` attribute:
+
+- [Google](https://google.com/)
+- [GitLab Root](<%= Gitlab.config.gitlab.url %>)
+
### Reference Filters (e.g., <%= issue.to_reference %>)
References should be parseable even inside _<%= merge_request.to_reference %>_ emphasis.