diff --git a/defaults/gitlab-ci.yml b/defaults/gitlab-ci.yml index 4c2e37e..5c99ea8 100644 --- a/defaults/gitlab-ci.yml +++ b/defaults/gitlab-ci.yml @@ -1,22 +1,8 @@ -{{#GITLABCOVERAGE}} -stages: - - test - - coverage -{{/GITLABCOVERAGE}} Julia {{VERSION}}: - stage: test image: julia:{{VERSION}} - tags: - - docker - script: - julia -e 'using Pkg; Pkg.build(); Pkg.test({{#GITLABCOVERAGE}}; coverage=true{{/GITLABCOVERAGE}})' + script: julia --project='.' -e 'using Pkg; Pkg.build(); Pkg.test({{#GITLABCOVERAGE}}; coverage=true{{/GITLABCOVERAGE}})' {{#GITLABCOVERAGE}} -Coverage: - stage: coverage coverage: /Test Coverage (\d+\.\d+%)/ - image: julia:{{VERSION}} - tags: - - docker - before_script: apt-get update && apt-get -y install git make unzip gcc bzip2 - script: julia -e 'using Pkg; Pkg.add("Coverage"); using Coverage; c, t = get_summary(process_folder()); @printf("Test Coverage %.2f%%\n", 100c/t)' + after_script: + - julia -e 'using Printf; using Pkg; Pkg.add("Coverage"); using Coverage; c, t = get_summary(process_folder()); @printf "Test Coverage %.2f%%\n" 100c/t' {{/GITLABCOVERAGE}}