Class: Fried::Test::Directory::GetFilesByPattern::Substitute

Inherits:
Object
  • Object
show all
Includes:
Telemetry
Defined in:
lib/fried/test/directory/get_files_by_pattern.rb

Instance Method Summary collapse

Methods included from Telemetry

#record, #recorded?, #recorded_times?, #recorded_with?

Constructor Details

#initialize(files = []) ⇒ Substitute

Returns a new instance of Substitute.



18
19
20
# File 'lib/fried/test/directory/get_files_by_pattern.rb', line 18

def initialize(files = [])
  @files = files
end

Instance Method Details

#call(pattern, flag = 0) ⇒ Object



22
23
24
25
# File 'lib/fried/test/directory/get_files_by_pattern.rb', line 22

def call(pattern, flag = 0)
  record :call, [pattern, flag]
  files.map(&:to_s)
end