Skip to content

Commit 9fc5d1e

Browse files
committed
spec/need_kconfig_format_spec.rb: rename is_erb_file to erb_file?
Signed-off-by: Philip Li <[email protected]>
1 parent 158d226 commit 9fc5d1e

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

spec/need_kconfig_format_spec.rb

+3-3
Original file line numberDiff line numberDiff line change
@@ -42,7 +42,7 @@ def load_yaml_with_conditionals(file_path)
4242
YAML.load(yaml_content)
4343
end
4444

45-
def is_erb_file(file_path)
45+
def erb_file?(file_path)
4646
File.foreach(file_path) { |line| return true if line.include?('<%') || line.include?('<%=') }
4747
false
4848
end
@@ -53,8 +53,8 @@ def is_erb_file(file_path)
5353
.each do |file|
5454
begin
5555
yaml_data = load_yaml_with_conditionals(file)
56-
# next if yaml_data.nil? || !yaml_data.is_a?(Hash) || is_erb_file(file)
57-
next unless yaml_data.is_a?(Hash) && !is_erb_file(file)
56+
# next if yaml_data.nil? || !yaml_data.is_a?(Hash) || erb_file?(file)
57+
next unless yaml_data.is_a?(Hash) && !erb_file?(file)
5858

5959
kconfig_section = yaml_data['need_kconfig']
6060

0 commit comments

Comments
 (0)