Module: HamlLint

Defined in:
lib/haml_lint/version.rb,
lib/haml_lint/cli.rb,
lib/haml_lint/lint.rb,
lib/haml_lint/utils.rb,
lib/haml_lint/linter.rb,
lib/haml_lint/logger.rb,
lib/haml_lint/report.rb,
lib/haml_lint/runner.rb,
lib/haml_lint/source.rb,
lib/haml_lint/adapter.rb,
lib/haml_lint/options.rb,
lib/haml_lint/document.rb,
lib/haml_lint/reporter.rb,
lib/haml_lint/severity.rb,
lib/haml_lint/constants.rb,
lib/haml_lint/directive.rb,
lib/haml_lint/rake_task.rb,
lib/haml_lint/file_finder.rb,
lib/haml_lint/parsed_ruby.rb,
lib/haml_lint/ruby_parser.rb,
lib/haml_lint/haml_visitor.rb,
lib/haml_lint/configuration.rb,
lib/haml_lint/linter/syntax.rb,
lib/haml_lint/adapter/haml_5.rb,
lib/haml_lint/adapter/haml_6.rb,
lib/haml_lint/linter/rubocop.rb,
lib/haml_lint/reporter/hooks.rb,
lib/haml_lint/reporter/utils.rb,
lib/haml_lint/linter/alt_text.rb,
lib/haml_lint/linter/id_names.rb,
lib/haml_lint/linter/tag_name.rb,
lib/haml_lint/linter_registry.rb,
lib/haml_lint/linter_selector.rb,
lib/haml_lint/node_transformer.rb,
lib/haml_lint/version_comparer.rb,
lib/haml_lint/linter/indentation.rb,
lib/haml_lint/linter/line_length.rb,
lib/haml_lint/linter/repeated_id.rb,
lib/haml_lint/linter/view_length.rb,
lib/haml_lint/linter/empty_script.rb,
lib/haml_lint/linter/implicit_div.rb,
lib/haml_lint/configuration_loader.rb,
lib/haml_lint/linter/final_newline.rb,
lib/haml_lint/linter/inline_styles.rb,
lib/haml_lint/linter/ruby_comments.rb,
lib/haml_lint/comment_configuration.rb,
lib/haml_lint/linter/alignment_tabs.rb,
lib/haml_lint/linter/multiline_pipe.rb,
lib/haml_lint/spec/normalize_indent.rb,
lib/haml_lint/linter/html_attributes.rb,
lib/haml_lint/linter/no_placeholders.rb,
lib/haml_lint/reporter/hash_reporter.rb,
lib/haml_lint/reporter/json_reporter.rb,
lib/haml_lint/linter/multiline_script.rb,
lib/haml_lint/reporter/github_reporter.rb,
lib/haml_lint/linter/classes_before_ids.rb,
lib/haml_lint/linter/instance_variables.rb,
lib/haml_lint/reporter/default_reporter.rb,
lib/haml_lint/spec/matchers/report_lint.rb,
lib/haml_lint/linter/space_before_script.rb,
lib/haml_lint/linter/trailing_whitespace.rb,
lib/haml_lint/reporter/progress_reporter.rb,
lib/haml_lint/spec/shared_linter_context.rb,
lib/haml_lint/linter/consecutive_comments.rb,
lib/haml_lint/linter/trailing_empty_lines.rb,
lib/haml_lint/linter/leading_comment_space.rb,
lib/haml_lint/reporter/checkstyle_reporter.rb,
lib/haml_lint/linter/empty_object_reference.rb,
lib/haml_lint/reporter/offense_count_reporter.rb,
lib/haml_lint/linter/unnecessary_interpolation.rb,
lib/haml_lint/linter/unnecessary_string_output.rb,
lib/haml_lint/linter/consecutive_silent_scripts.rb,
lib/haml_lint/reporter/disabled_config_reporter.rb,
lib/haml_lint/linter/object_reference_attributes.rb,
lib/haml_lint/linter/space_inside_hash_attributes.rb,
lib/haml_lint/spec/shared_rubocop_autocorrect_context.rb,
lib/haml_lint/linter/class_attribute_with_static_value.rb

Overview

Makes writing tests for linters a lot DRYer by taking any currently ‘haml` variable defined via `let` and normalizing it and running the linter against it, allowing specs to simply specify whether a lint was reported.

Defined Under Namespace

Modules: Exceptions, HamlVisitor, LinterRegistry, RubyExtraction, Spec, Tree, Utils Classes: Adapter, CLI, CommentConfiguration, Configuration, ConfigurationLoader, Directive, Document, FileFinder, Lint, Linter, LinterSelector, Logger, NoSuchLinter, NodeTransformer, OffenseCollector, Options, ParsedRuby, RakeTask, Report, Reporter, RubocopConfigStore, RubyParser, Runner, Severity, Source, VersionComparer

Constant Summary collapse

VERSION =
'0.58.0'
HOME =
File.expand_path(File.join(File.dirname(__FILE__), '..', '..')).freeze
APP_NAME =
'haml-lint'
REPO_URL =
'https://github.com/sds/haml-lint'
BUG_REPORT_URL =
"#{REPO_URL}/issues".freeze