Skip to content
This repository
Browse code

Test for "no-referrer" in HTML report links

  • Loading branch information...
commit eba89befc06cbc569bdea967c9a5067842974bde 1 parent 3ecbab0
Justin authored March 15, 2013

Showing 1 changed file with 3 additions and 0 deletions. Show diff stats Hide diff stats

  1. 3  test/tests/test_report_generation.rb
3  test/tests/test_report_generation.rb
@@ -6,6 +6,9 @@ def test_html_sanity
6 6
 
7 7
     assert report.is_a? String
8 8
     assert report.match(/\A<!DOCTYPE HTML SYSTEM>.*<\/html>\z/m)
  9
+    report.scan(/<a[^>]+>/).each do |a|
  10
+      assert a.include?("no-referrer"), "#{a} does not include 'no-referrer'"
  11
+    end
9 12
   end
10 13
 
11 14
   def test_json_sanity

0 notes on commit eba89be

Please sign in to comment.
Something went wrong with that request. Please try again.