Skip to content

Commit e9eb4af

Browse files
committed
commenting
1 parent 066c79a commit e9eb4af

File tree

2 files changed

+11
-0
lines changed

2 files changed

+11
-0
lines changed

lib/arduino_ci/ci_config.rb

+4
Original file line numberDiff line numberDiff line change
@@ -147,15 +147,19 @@ def platform_definition(platform_name)
147147
deep_clone(defn)
148148
end
149149

150+
# the URL that gives the download info for a given package (a JSON file).
151+
# this is NOT where the package comes from.
150152
def package_url(package)
151153
return nil if @package_info[package].nil?
152154
@package_info[package][:url]
153155
end
154156

157+
# platforms to build [the examples on]
155158
def platforms_to_build
156159
@compile_info[:platforms]
157160
end
158161

162+
# platforms to unit test [the tests on]
159163
def platforms_to_unittest
160164
@unittest_info[:platforms]
161165
end

lib/arduino_ci/cpp_library.rb

+7
Original file line numberDiff line numberDiff line change
@@ -23,31 +23,38 @@ def cpp_files_in(some_dir)
2323
Find.find(some_dir).select { |path| CPP_EXTENSIONS.include?(File.extname(path)) }
2424
end
2525

26+
# CPP files that are part of the project library under test
2627
def cpp_files
2728
cpp_files_in(@base_dir).reject { |p| p.start_with?(tests_dir) }
2829
end
2930

31+
# CPP files that are part of the arduino mock library we're providing
3032
def cpp_files_arduino
3133
cpp_files_in(ARDUINO_HEADER_DIR)
3234
end
3335

36+
# CPP files that are part of the unit test library we're providing
3437
def cpp_files_unittest
3538
cpp_files_in(UNITTEST_HEADER_DIR)
3639
end
3740

41+
# The directory where we expect to find unit test defintions provided by the user
3842
def tests_dir
3943
File.join(@base_dir, "test")
4044
end
4145

46+
# The files provided by the user that contain unit tests
4247
def test_files
4348
cpp_files_in(tests_dir)
4449
end
4550

51+
# Find all directories in the project library that include C++ header files
4652
def header_dirs
4753
files = Find.find(@base_dir).select { |path| HPP_EXTENSIONS.include?(File.extname(path)) }
4854
files.map { |path| File.dirname(path) }.uniq
4955
end
5056

57+
# wrapper for the GCC command
5158
def run_gcc(*args, **kwargs)
5259
# TODO: detect env!!
5360
full_args = ["g++"] + args

0 commit comments

Comments
 (0)