class Guard::Compat::Test::Template

Public Class Methods

new(plugin_class) click to toggle source
# File lib/guard/compat/test/template.rb, line 55
def initialize(plugin_class)
  name = plugin_class.to_s.sub('Guard::', '').downcase
  path = format('lib/guard/%s/templates/Guardfile', name)
  content = File.read(path)
  @session = Session.new(path, content)
end

Public Instance Methods

changed(file) click to toggle source
# File lib/guard/compat/test/template.rb, line 62
def changed(file)
  @session.match(file)
end