Module: HTMLProofer

Defined in:
lib/html-proofer.rb,
lib/html-proofer/log.rb,
lib/html-proofer/cache.rb,
lib/html-proofer/check.rb,
lib/html-proofer/issue.rb,
lib/html-proofer/utils.rb,
lib/html-proofer/runner.rb,
lib/html-proofer/element.rb,
lib/html-proofer/version.rb,
lib/html-proofer/configuration.rb,
lib/html-proofer/url_validator.rb

Defined Under Namespace

Modules: Configuration, Utils Classes: Cache, Check, Element, Issue, Log, Runner, SortedIssues, UrlValidator

Constant Summary collapse

VERSION =
'3.2.0'.freeze

Class Method Summary collapse

Class Method Details

.check_directories(directories, options = {}) ⇒ Object


35
36
37
38
39
# File 'lib/html-proofer.rb', line 35

def check_directories(directories, options = {})
  fail ArgumentError unless directories.is_a?(Array)
  options[:type] = :directory
  HTMLProofer::Runner.new(directories, options)
end

.check_directory(directory, options = {}) ⇒ Object


28
29
30
31
32
# File 'lib/html-proofer.rb', line 28

def check_directory(directory, options = {})
  fail ArgumentError unless directory.is_a?(String)
  options[:type] = :directory
  HTMLProofer::Runner.new([directory], options)
end

.check_file(file, options = {}) ⇒ Object


21
22
23
24
25
# File 'lib/html-proofer.rb', line 21

def check_file(file, options = {})
  fail ArgumentError unless file.is_a?(String)
  options[:type] = :file
  HTMLProofer::Runner.new(file, options)
end

42
43
44
45
46
# File 'lib/html-proofer.rb', line 42

def check_links(links, options = {})
  fail ArgumentError unless links.is_a?(Array)
  options[:type] = :links
  HTMLProofer::Runner.new(links, options)
end