diff --git a/CHANGELOG.md b/CHANGELOG.md index 50ab5185..f16f8b5e 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -10,6 +10,7 @@ and this project adheres to [Semantic Versioning](http://semver.org/). - Special handling of attempts to run the `arduino_ci.rb` CI script against the ruby library instead of an actual Arduino project - Explicit checks for attemping to test `arduino_ci` itself as if it were a library, resolving a minor annoyance to this developer. - Code coverage tooling +- Explicit check and warning for library directory names that do not match our guess of what the library should/would be called ### Changed - Arduino backend is now `arduino-cli` version `0.13.0` @@ -28,6 +29,7 @@ and this project adheres to [Semantic Versioning](http://semver.org/). - `ARDUINO_CI_SKIP_SPLASH_SCREEN_RSPEC_TESTS` no longer affects any tests because there are no longer splash screens since switching to `arduino-cli` ### Fixed +- Mismatches between library names in `library.properties` and the directory names, which can cause cryptic failures ### Security diff --git a/SampleProjects/ExcludeSomething/library.properties b/SampleProjects/ExcludeSomething/library.properties index 1745537f..64065e1f 100644 --- a/SampleProjects/ExcludeSomething/library.properties +++ b/SampleProjects/ExcludeSomething/library.properties @@ -1,4 +1,4 @@ -name=TestSomething +name=ExcludeSomething version=0.1.0 author=Ian Katz maintainer=Ian Katz diff --git a/SampleProjects/NetworkLib/library.properties b/SampleProjects/NetworkLib/library.properties index 2efc89bd..61e2d980 100644 --- a/SampleProjects/NetworkLib/library.properties +++ b/SampleProjects/NetworkLib/library.properties @@ -1,4 +1,4 @@ -name=Ethernet +name=NetworkLib version=0.1.0 author=James Foster maintainer=James Foster diff --git a/exe/arduino_ci.rb b/exe/arduino_ci.rb index 706edd6e..0627604e 100755 --- a/exe/arduino_ci.rb +++ b/exe/arduino_ci.rb @@ -375,8 +375,15 @@ def perform_example_compilation_tests(cpp_library, config) inform("Located arduino-cli binary") { @backend.binary_path.to_s } # initialize library under test +cpp_library_path = Pathname.new(".") cpp_library = assure("Installing library under test") do - @backend.install_local_library(Pathname.new(".")) + @backend.install_local_library(cpp_library_path) +end + +assumed_name = @backend.name_of_library(cpp_library_path) +ondisk_name = cpp_library_path.realpath.basename +if assumed_name != ondisk_name + inform("WARNING") { "Installed library named '#{assumed_name}' has directory name '#{ondisk_name}'" } end if !cpp_library.nil?