diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml index ad27460006921a1e4c0a5e7334510dedc0349d3b..b5229450cddc44409aeece7731d8bad08d5b1abc 100644 --- a/.gitlab-ci.yml +++ b/.gitlab-ci.yml @@ -16,7 +16,11 @@ build: - cd build - cmake .. - cmake --build . - - ctest + - ctest -V >& test.log + - gzip -9 test.log + artifacts: + paths: + - test.log.gz # code_quality: # image: docker:stable diff --git a/CMakeLists.txt b/CMakeLists.txt index d2d4df9b12cb9bc92a2251bc99abda96b8507a0a..f2670f9a147c3e4865cff1d9ba870cf5585fc09d 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -37,10 +37,14 @@ if(NOT CMAKE_BUILD_TYPE AND NOT CMAKE_CONFIGURATION_TYPES) endif() # enable warnings and disallow non-standard language -set(CMAKE_CXX_FLAGS "-Wall -pedantic -Wextra -Wno-ignored-qualifiers -Wno-nonportable-include-path") +set(CMAKE_CXX_FLAGS "-Wall -pedantic -Wextra -Wno-ignored-qualifiers") set(CMAKE_CXX_FLAGS_DEBUG "${CMAKE_CXX_FLAGS} -O0 -g") set(CMAKE_CXX_FLAGS_RELEASE "${CMAKE_CXX_FLAGS} -O3") +# clang produces a lot of unecessary warnings without this: +add_compile_options("$<$<CXX_COMPILER_ID:Clang>:-Wno-nonportable-include-path>") + + # unit testing coverage, does not work yet #include (CodeCoverage) ##set(COVERAGE_LCOV_EXCLUDES 'Documentation/*') diff --git a/Documentation/Examples/cascade_example.cc b/Documentation/Examples/cascade_example.cc index 451a3800ddcedf22e7c69cf6d32f817e9733e990..a76ce24b4b2dcbb1f70a583a296b00372e90ff96 100644 --- a/Documentation/Examples/cascade_example.cc +++ b/Documentation/Examples/cascade_example.cc @@ -238,7 +238,7 @@ int main() { setup::Stack stack; stack.Clear(); const hep::EnergyType E0 = 100_TeV; - double theta = 45.; + double theta = 0.; double phi = 0.; { auto particle = stack.NewParticle();