Sha256: f65b5332379185eec5bb1906560af0aff53e592e1d1bd5e347c8c76f4e311575
Contents?: true
Size: 725 Bytes
Versions: 56
Compression:
Stored size: 725 Bytes
Contents
module Danger class Markdown attr_accessor :message, :file, :line def initialize(message, file = nil, line = nil) self.message = message self.file = file self.line = line end def ==(other) return false if other.nil? return false unless other.kind_of? self.class other.message == message && other.file == file && other.line == line end # @return [Boolean] returns true if is a file or line, false otherwise def inline? file || line end def to_s extra = [] extra << "file: #{file}" unless file extra << "line: #{line}" unless line "Markdown #{message} { #{extra.join ', '.freeze} }" end end end
Version data entries
56 entries across 56 versions & 1 rubygems