Skip to content

Commit f8cb186

Browse files
author
James Foster
committed
Merge branch 'cmd_line_defines' into client_server
2 parents 6ee766e + 89cff26 commit f8cb186

File tree

1 file changed

+2
-3
lines changed

1 file changed

+2
-3
lines changed

lib/arduino_ci/cpp_library.rb

+2-3
Original file line numberDiff line numberDiff line change
@@ -334,9 +334,8 @@ def build_for_test_with_configuration(test_file, aux_libraries, gcc_binary, ci_g
334334
]
335335
end
336336
arg_sets << test_args(aux_libraries, ci_gcc_config)
337-
if (arg_sets.flatten(1).index{|s| s.include?("-DARDUINO=")} == nil)
338-
arg_sets << ["-DARDUINO=100"]
339-
end
337+
index = arg_sets.flatten(1).index { |s| s.include?("-DARDUINO=") }
338+
arg_sets << ["-DARDUINO=100"] if index.nil?
340339
arg_sets << cpp_files_libraries(aux_libraries).map(&:to_s)
341340
arg_sets << [test_file.to_s]
342341
args = arg_sets.flatten(1)

0 commit comments

Comments
 (0)