diff --git a/.github/workflows/test.yml b/.github/workflows/test.yml index 0aa55f9c..f8043e32 100644 --- a/.github/workflows/test.yml +++ b/.github/workflows/test.yml @@ -49,6 +49,15 @@ jobs: uses: julia-actions/setup-julia@v1 with: version: ${{ matrix.julia-version }} + - name: Remove compat entry for old julia versions + # This is needed for julia 1.0-1.3, see https://julialang.slack.com/archives/C67910KEH/p1697548190422019?thread_ts=1697546952.011759&cid=C67910KEH + if: matrix.julia-version == '1.0' || matrix.julia-version == '1.1' || matrix.julia-version == '1.2' || matrix.julia-version == '1.3' + shell: julia --project=. --color=yes {0} + run: | + using Pkg.TOML + prj = TOML.parsefile("Project.toml") + delete!(prj["compat"], "Test") + open(io -> TOML.print(io, prj), "Project.toml", "w") - uses: julia-actions/julia-runtest@v1 - uses: julia-actions/julia-processcoverage@v1 - uses: codecov/codecov-action@v3 diff --git a/CHANGELOG.md b/CHANGELOG.md index 197b6af8..ded3c158 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -7,9 +7,16 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0 ## [Unreleased] +## [0.7.4] - 2023-10-24 + +### Added + +- `test_deps_compat` has two new kwargs `check_extras` and `check_weakdeps` to extend the test to these dependency categories. They are not run by default. ([#200](https://github.com/JuliaTesting/Aqua.jl/pull/200)) + ### Changed - The docstring for `test_stale_deps` explains the situation with package extensions. ([#203](https://github.com/JuliaTesting/Aqua.jl/pull/203)) +- The logo of Aqua.jl has been updated. ([#128](https://github.com/JuliaTesting/Aqua.jl/pull/128)) ### Removed diff --git a/Makefile b/Makefile index 1b937af8..eb330cd4 100644 --- a/Makefile +++ b/Makefile @@ -1,2 +1,12 @@ -badge.svg: - curl -o 'badge.svg' 'https://img.shields.io/badge/tested_with-Aqua.jl-05C3DD.svg?logo=data:image/svg+xml;base64,PD94bWwgdmVyc2lvbj0iMS4wIiBlbmNvZGluZz0iVVRGLTgiIHN0YW5kYWxvbmU9Im5vIj8+CjwhLS0gQ3JlYX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7c3Ryb2tlLWRhc2hhcnJheTpub25lO3N0cm9rZS1vcGFjaXR5OjEiCiAgICAgaWQ9InBhdGgxMDEwMy0zIgogICAgIGN4PSIzLjg4NDQ5NjUiCiAgICAgY3k9IjIuNTgyMTc1IgogICAgIHI9IjAuOTIwODU3NzMiIC8+CiAgPGcKICAgICBpZD0ibGF5ZXIyIgogICAgIHN0eWxlPSJkaXNwbGF5Om5vbmUiCiAgICAgdHJhbnNmb3JtPSJ0cmFuc2xhdGUoMC43OTM3NTA2MykiIC8+Cjwvc3ZnPgo=' +all: generate_badge generate_favicon + +.PHONY: all generate_badge generate_favicon + +generate_badge: + SVG_BASE64=$(shell base64 -w 0 docs/src/assets/logo.svg); \ + curl -o "badge.svg" "https://img.shields.io/badge/tested_with-Aqua.jl-05C3DD.svg?logo=data:image/svg+xml;base64,$$SVG_BASE64" + +generate_favicon: + convert -background none docs/src/assets/logo.svg -resize 256x256 -gravity center -extent 256x256 logo.png + convert logo.png -define icon:auto-resize=256,64,48,32,16 docs/src/assets/favicon.ico + rm logo.png diff --git a/Project.toml b/Project.toml index 6bab7582..658cd813 100644 --- a/Project.toml +++ b/Project.toml @@ -1,7 +1,7 @@ name = "Aqua" uuid = "4c88cf16-eb10-579e-8560-4a9242c79595" authors = ["Takafumi Arakaki and contributors"] -version = "0.7.3" +version = "0.7.4" [deps] Compat = "34da2185-b29b-5c13-b0c7-acf172513d20" @@ -10,6 +10,8 @@ Test = "8dfed614-e22c-5e08-85e1-65c5234f0b40" [compat] Compat = "3.12, 4" +Pkg = "1.0" +Test = "1.0" julia = "1.0" [extras] diff --git a/badge.svg b/badge.svg index 397e562f..a9fec3f3 100644 --- a/badge.svg +++ b/badge.svg @@ -1 +1 @@ -tested with: Aqua.jltested withAqua.jl \ No newline at end of file +tested with: Aqua.jltested withAqua.jl \ No newline at end of file diff --git a/docs/make.jl b/docs/make.jl index 5cc0a9b3..5f912613 100644 --- a/docs/make.jl +++ b/docs/make.jl @@ -4,7 +4,10 @@ makedocs(; modules = [Aqua], pages = ["Home" => "index.md"], sitename = "Aqua.jl", - format = Documenter.HTML(; repolink = "https://github.com/JuliaTesting/Aqua.jl"), + format = Documenter.HTML(; + repolink = "https://github.com/JuliaTesting/Aqua.jl", + assets = ["assets/favicon.ico"], + ), authors = "Takafumi Arakaki", warnonly = true, ) diff --git a/docs/src/assets/favicon.ico b/docs/src/assets/favicon.ico new file mode 100644 index 00000000..08b95268 Binary files /dev/null and b/docs/src/assets/favicon.ico differ diff --git a/docs/src/assets/logo.svg b/docs/src/assets/logo.svg new file mode 100644 index 00000000..f0688324 --- /dev/null +++ b/docs/src/assets/logo.svg @@ -0,0 +1,60 @@ + + + + + + + + + + + diff --git a/src/deps_compat.jl b/src/deps_compat.jl index 591af779..15c9c16f 100644 --- a/src/deps_compat.jl +++ b/src/deps_compat.jl @@ -9,12 +9,43 @@ each package listed under `deps`. them. # Keyword Arguments +## Test choosers +- `check_extras = false`: If true, additionally check "extras". A NamedTuple + can be used to pass keyword arguments with test options (see below). +- `check_weakdeps = false`: If true, additionally check "weakdeps". A NamedTuple + can be used to pass keyword arguments with test options (see below). + +## Test options +If these keyword arguments are set directly, they only apply to the standard test +for "deps". To apply them to "extras" and "weakdeps", pass them as a NamedTuple +to the corresponding `check_\$x` keyword argument. - `broken::Bool = false`: If true, it uses `@test_broken` instead of - `@test`. + `@test` for "deps". - `ignore::Vector{Symbol}`: names of dependent packages to be ignored. """ -function test_deps_compat(pkg::PkgId; broken::Bool = false, kwargs...) - result = find_missing_deps_compat(pkg; kwargs...) +function test_deps_compat( + pkg::PkgId; + check_extras = false, # Maybe switch to `true` for next breaking version + check_weakdeps = false, # Maybe switch to `true` for next breaking version + kwargs..., +) + @testset "$pkg deps" begin + test_deps_compat(pkg, "deps"; kwargs...) + end + if check_extras !== false + @testset "$pkg extras" begin + result = test_deps_compat(pkg, "extras"; askwargs(check_extras)...) + end + end + if check_weakdeps !== false + @testset "$pkg weakdeps" begin + result = test_deps_compat(pkg, "weakdeps"; askwargs(check_weakdeps)...) + end + end +end + +function test_deps_compat(pkg::PkgId, deps_type::String; broken::Bool = false, kwargs...) + result = find_missing_deps_compat(pkg, deps_type; kwargs...) if broken @test_broken isempty(result) else diff --git a/src/unbound_args.jl b/src/unbound_args.jl index 35a15601..4f651cde 100644 --- a/src/unbound_args.jl +++ b/src/unbound_args.jl @@ -3,7 +3,7 @@ Test that all methods in `module` and its submodules do not have unbound type parameters. An unbound type parameter is a type parameter -with a `where`, that does not occurr in the signature of some dispatch +with a `where`, that does not occur in the signature of some dispatch of the method. # Keyword Arguments diff --git a/test/test_smoke.jl b/test/test_smoke.jl index bc46b329..bf2fc487 100644 --- a/test/test_smoke.jl +++ b/test/test_smoke.jl @@ -16,7 +16,7 @@ Aqua.test_all( undefined_exports = false, project_extras = false, stale_deps = false, - deps_compat = false, + deps_compat = (; check_extras = true, check_weakdeps = true), piracy = false, )