diff options
author | Benjamin Neff <benjamin@coding4coffee.ch> | 2017-08-27 22:49:29 +0300 |
---|---|---|
committer | Benjamin Neff <benjamin@coding4coffee.ch> | 2017-09-17 20:27:47 +0300 |
commit | 44ebc7375a3dcf838fb1959b6828cac31fbcb498 (patch) | |
tree | d84a19a5e03cf91afc81a48439dc742e70619566 | |
parent | 45e714776ebcbb13d6f40f67d2a6414820e362f0 (diff) |
Remove unused spec-doc.rb
closes #7594
-rw-r--r-- | spec/spec-doc.rb | 25 | ||||
-rw-r--r-- | spec/spec_helper.rb | 1 |
2 files changed, 0 insertions, 26 deletions
diff --git a/spec/spec-doc.rb b/spec/spec-doc.rb deleted file mode 100644 index d1e778b12..000000000 --- a/spec/spec-doc.rb +++ /dev/null @@ -1,25 +0,0 @@ -class SpecDoc - def initialize(response) - @html = Nokogiri::HTML(response.body) - end - - def method_missing(method, *args) - @html.send method, *args - end - - def has_content?(string) - escaped = string.gsub("'", "\\'") - @html.xpath("//*[contains(text(), '#{escaped}')]").any? - end - def has_no_content?(string) - ! has_content?(string) - end - - def has_link?(text) - @html.xpath("//a[text()='#{text}']").any? - end -end - -def doc - SpecDoc.new response -end diff --git a/spec/spec_helper.rb b/spec/spec_helper.rb index 493ee8b36..61a573b67 100644 --- a/spec/spec_helper.rb +++ b/spec/spec_helper.rb @@ -9,7 +9,6 @@ Coveralls.wear!('rails') require File.join(File.dirname(__FILE__), "..", "config", "environment") require Rails.root.join("spec", "helper_methods") -require Rails.root.join("spec", "spec-doc") require "rspec/rails" require "webmock/rspec" require "factory_girl" |