Class: FilePresenceRule

Inherits:
Rule
  • Object
show all
Defined in:
lib/technologist/rules/file_presence_rule.rb

Instance Attribute Summary collapse

Attributes inherited from Rule

#framework

Instance Method Summary collapse

Methods inherited from Rule

#initialize

Constructor Details

This class inherits a constructor from Rule

Instance Attribute Details

#file_nameObject

Returns the value of attribute file_name.



4
5
6
# File 'lib/technologist/rules/file_presence_rule.rb', line 4

def file_name
  @file_name
end

Instance Method Details

#matches?(repository) ⇒ Boolean

Returns:

  • (Boolean)


6
7
8
# File 'lib/technologist/rules/file_presence_rule.rb', line 6

def matches?(repository)
  repository.file_exists?(file_name)
end