Skip to content

Commit

Permalink
Remove check for missing files
Browse files Browse the repository at this point in the history
  • Loading branch information
Marek Kowalcze committed Apr 16, 2016
1 parent d717388 commit d54bafb
Showing 1 changed file with 2 additions and 12 deletions.
14 changes: 2 additions & 12 deletions lib/polish_geeks/dev_tools/commands/examples_comparator.rb
Original file line number Diff line number Diff line change
Expand Up @@ -13,12 +13,8 @@ def execute

Dir[config_path].each do |example_file|
dedicated_file = example_file.gsub('.example', '')
if File.exist?(dedicated_file)
header = compare_header(example_file, dedicated_file)
@output << compare_output(header, example_file, dedicated_file)
else
@output << missing_file(dedicated_file)
end
header = compare_header(example_file, dedicated_file)
@output << compare_output(header, example_file, dedicated_file)
end
end

Expand Down Expand Up @@ -81,12 +77,6 @@ def failed_compare(compare_header, details = '')
# TODO: format details properly
"\e[31m failed\e[0m - #{compare_header} - structure not equal#{details}\n"
end

# @param [String] dedicated_file path to config file which is missing
# @return [String] failed message for missing file
def missing_file(dedicated_file)
"\e[31m failed\e[0m - #{File.basename(dedicated_file)} - file is missing\n"
end
end
end
end
Expand Down

0 comments on commit d54bafb

Please sign in to comment.