Merge pull request #123 from invenia/cdg/fixes
Make tests pass reliably, fix coverage badges, update reference tests for 1.3
This commit is contained in:
commit
a41187be1c
@ -7,7 +7,6 @@ os:
|
||||
- windows
|
||||
julia:
|
||||
- 1.0
|
||||
- 1.2
|
||||
- 1.3
|
||||
- nightly
|
||||
before_script:
|
||||
@ -17,7 +16,6 @@ script: travis_wait julia --project -e 'using Pkg; Pkg.test(; coverage=true)'
|
||||
matrix:
|
||||
fast_finish: true
|
||||
allow_failures:
|
||||
- julia: 1.3
|
||||
- julia: nightly
|
||||
include:
|
||||
- arch: x86
|
||||
|
@ -49,9 +49,9 @@ uuid = "d6f4376e-aef5-505a-96c1-9c027394607a"
|
||||
|
||||
[[Mustache]]
|
||||
deps = ["Printf", "Tables"]
|
||||
git-tree-sha1 = "f39de3a12232eb47bd0629b3a661054287780276"
|
||||
git-tree-sha1 = "e06eef2abee113c49695f5347668e15d4c02978a"
|
||||
uuid = "ffc61752-8dc7-55ee-8c37-f3e9cdd09e70"
|
||||
version = "0.5.13"
|
||||
version = "1.0.0"
|
||||
|
||||
[[OrderedCollections]]
|
||||
deps = ["Random", "Serialization", "Test"]
|
||||
@ -66,7 +66,7 @@ uuid = "d96e819e-fc66-5662-9728-84c9c7592b0a"
|
||||
version = "0.12.0"
|
||||
|
||||
[[Pkg]]
|
||||
deps = ["Dates", "LibGit2", "Markdown", "Printf", "REPL", "Random", "SHA", "UUIDs"]
|
||||
deps = ["Dates", "LibGit2", "Libdl", "Logging", "Markdown", "Printf", "REPL", "Random", "SHA", "UUIDs"]
|
||||
uuid = "44cfe95a-1eb2-52ea-b672-e2afdf69b78f"
|
||||
|
||||
[[Printf]]
|
||||
|
@ -18,10 +18,10 @@ uuid = "ffbed154-4ef7-542d-bbb7-c09d3a79fcae"
|
||||
version = "0.8.1"
|
||||
|
||||
[[Documenter]]
|
||||
deps = ["Base64", "DocStringExtensions", "InteractiveUtils", "JSON", "LibGit2", "Logging", "Markdown", "REPL", "Test", "Unicode"]
|
||||
git-tree-sha1 = "d45c163c7a3ae293c15361acc52882c0f853f97c"
|
||||
deps = ["Base64", "Dates", "DocStringExtensions", "InteractiveUtils", "JSON", "LibGit2", "Logging", "Markdown", "REPL", "Test", "Unicode"]
|
||||
git-tree-sha1 = "885467cebde4639a3d81953652cc53ff5a73cb87"
|
||||
uuid = "e30172f5-a6a5-5a46-863b-614d45cd2de4"
|
||||
version = "0.23.4"
|
||||
version = "0.24.3"
|
||||
|
||||
[[InteractiveUtils]]
|
||||
deps = ["Markdown"]
|
||||
@ -36,6 +36,9 @@ version = "0.21.0"
|
||||
[[LibGit2]]
|
||||
uuid = "76f85450-5226-5b5a-8eaa-529ad045b433"
|
||||
|
||||
[[Libdl]]
|
||||
uuid = "8f399da3-3557-5675-b5ff-fb832c97cbdb"
|
||||
|
||||
[[Logging]]
|
||||
uuid = "56ddb016-857b-54e1-b83d-db4d58db5568"
|
||||
|
||||
@ -48,12 +51,12 @@ uuid = "a63ad114-7e13-5084-954f-fe012c677804"
|
||||
|
||||
[[Parsers]]
|
||||
deps = ["Dates", "Test"]
|
||||
git-tree-sha1 = "ef0af6c8601db18c282d092ccbd2f01f3f0cd70b"
|
||||
git-tree-sha1 = "0139ba59ce9bc680e2925aec5b7db79065d60556"
|
||||
uuid = "69de0a69-1ddd-5017-9359-2bf0b02dc9f0"
|
||||
version = "0.3.7"
|
||||
version = "0.3.10"
|
||||
|
||||
[[Pkg]]
|
||||
deps = ["Dates", "LibGit2", "Markdown", "Printf", "REPL", "Random", "SHA", "UUIDs"]
|
||||
deps = ["Dates", "LibGit2", "Libdl", "Logging", "Markdown", "Printf", "REPL", "Random", "SHA", "UUIDs"]
|
||||
uuid = "44cfe95a-1eb2-52ea-b672-e2afdf69b78f"
|
||||
|
||||
[[Printf]]
|
||||
|
@ -7,7 +7,7 @@ Strings are left in their original form.
|
||||
format_version(v::VersionNumber) = "$(v.major).$(v.minor)"
|
||||
format_version(v::AbstractString) = string(v)
|
||||
|
||||
const ALLOWED_FAILURES = ["1.3", "nightly"] # TODO: Update this list with new RCs.
|
||||
const ALLOWED_FAILURES = ["nightly"] # TODO: Update this list with new RCs.
|
||||
const DEFAULT_CI_VERSIONS = map(format_version, [default_version(), VERSION, "nightly"])
|
||||
const DEFAULT_CI_VERSIONS_NO_NIGHTLY = map(format_version, [default_version(), VERSION])
|
||||
const EXTRA_VERSIONS_DOC = "- `extra_versions::Vector`: Extra Julia versions to test, as strings or `VersionNumber`s."
|
||||
|
@ -45,6 +45,10 @@ badges(::Coveralls) = Badge(
|
||||
)
|
||||
|
||||
gitignore(::Union{Codecov, Coveralls}) = COVERAGE_GITIGNORE
|
||||
view(::Union{Codecov, Coveralls}, t::Template, pkg::AbstractString) = Dict(
|
||||
"PKG" => pkg,
|
||||
"USER" => t.user,
|
||||
)
|
||||
|
||||
"""
|
||||
is_coverage(::Plugin) -> Bool
|
||||
|
2
test/fixtures/AllPlugins/.appveyor.yml
vendored
2
test/fixtures/AllPlugins/.appveyor.yml
vendored
@ -2,7 +2,7 @@
|
||||
environment:
|
||||
matrix:
|
||||
- julia_version: 1.0
|
||||
- julia_version: 1.2
|
||||
- julia_version: 1.3
|
||||
- julia_version: nightly
|
||||
platform:
|
||||
- x64
|
||||
|
2
test/fixtures/AllPlugins/.cirrus.yml
vendored
2
test/fixtures/AllPlugins/.cirrus.yml
vendored
@ -4,7 +4,7 @@ task:
|
||||
name: FreeBSD
|
||||
env:
|
||||
JULIA_VERSION: 1.0
|
||||
JULIA_VERSION: 1.2
|
||||
JULIA_VERSION: 1.3
|
||||
JULIA_VERSION: nightly
|
||||
install_script:
|
||||
- sh -c "$(fetch https://raw.githubusercontent.com/ararslan/CirrusCI.jl/master/bin/install.sh -o -)"
|
||||
|
2
test/fixtures/AllPlugins/.drone.star
vendored
2
test/fixtures/AllPlugins/.drone.star
vendored
@ -1,7 +1,7 @@
|
||||
def main(ctx):
|
||||
pipelines = []
|
||||
for arch in ["amd64"]:
|
||||
for julia in ["1.0", "1.2"]:
|
||||
for julia in ["1.0", "1.3"]:
|
||||
pipelines.append(pipeline(arch, julia))
|
||||
return pipelines
|
||||
|
||||
|
@ -10,7 +10,7 @@ jobs:
|
||||
matrix:
|
||||
version:
|
||||
- '1.0'
|
||||
- '1.2'
|
||||
- '1.3'
|
||||
os:
|
||||
- ubuntu-latest
|
||||
- macOS-latest
|
||||
|
4
test/fixtures/AllPlugins/.gitlab-ci.yml
vendored
4
test/fixtures/AllPlugins/.gitlab-ci.yml
vendored
@ -19,7 +19,7 @@ Julia 1.0:
|
||||
image: julia:1.0
|
||||
<<: *script
|
||||
<<: *coverage
|
||||
Julia 1.2:
|
||||
image: julia:1.2
|
||||
Julia 1.3:
|
||||
image: julia:1.3
|
||||
<<: *script
|
||||
<<: *coverage
|
||||
|
2
test/fixtures/AllPlugins/.travis.yml
vendored
2
test/fixtures/AllPlugins/.travis.yml
vendored
@ -4,7 +4,7 @@ notifications:
|
||||
email: false
|
||||
julia:
|
||||
- 1.0
|
||||
- 1.2
|
||||
- 1.3
|
||||
- nightly
|
||||
os:
|
||||
- linux
|
||||
|
6
test/fixtures/AllPlugins/README.md
vendored
6
test/fixtures/AllPlugins/README.md
vendored
@ -1,11 +1,11 @@
|
||||
# AllPlugins
|
||||
|
||||
[](https://github.com/tester/AllPlugins.jl/workflows/CI/badge.svg)
|
||||
[](https://github.com/tester/AllPlugins.jl/actions)
|
||||
[](https://gitlab.com/tester/AllPlugins.jl/pipelines)
|
||||
[](https://gitlab.com/tester/AllPlugins.jl/commits/master)
|
||||
[](https://travis-ci.com/tester/AllPlugins.jl)
|
||||
[](https://ci.appveyor.com/project/tester/AllPlugins-jl)
|
||||
[](https://cloud.drone.io/tester/AllPlugins.jl)
|
||||
[](https://cirrus-ci.com/github/tester/AllPlugins.jl)
|
||||
[](https://codecov.io/gh//.jl)
|
||||
[](https://coveralls.io/github//.jl?branch=master)
|
||||
[](https://codecov.io/gh/tester/AllPlugins.jl)
|
||||
[](https://coveralls.io/github/tester/AllPlugins.jl?branch=master)
|
||||
|
@ -10,7 +10,7 @@ jobs:
|
||||
matrix:
|
||||
version:
|
||||
- '1.0'
|
||||
- '1.2'
|
||||
- '1.3'
|
||||
os:
|
||||
- ubuntu-latest
|
||||
- macOS-latest
|
||||
|
@ -1,5 +1,5 @@
|
||||
# DocumenterGitHubActions
|
||||
|
||||
[](https://github.com/tester/DocumenterGitHubActions.jl/workflows/CI/badge.svg)
|
||||
[](https://github.com/tester/DocumenterGitHubActions.jl/actions)
|
||||
[](https://tester.github.io/DocumenterGitHubActions.jl/stable)
|
||||
[](https://tester.github.io/DocumenterGitHubActions.jl/dev)
|
||||
|
2
test/fixtures/DocumenterTravis/.travis.yml
vendored
2
test/fixtures/DocumenterTravis/.travis.yml
vendored
@ -4,7 +4,7 @@ notifications:
|
||||
email: false
|
||||
julia:
|
||||
- 1.0
|
||||
- 1.2
|
||||
- 1.3
|
||||
- nightly
|
||||
os:
|
||||
- linux
|
||||
|
5
test/fixtures/WackyOptions/.appveyor.yml
vendored
5
test/fixtures/WackyOptions/.appveyor.yml
vendored
@ -1,14 +1,11 @@
|
||||
# Documentation: https://github.com/JuliaCI/Appveyor.jl
|
||||
environment:
|
||||
matrix:
|
||||
- julia_version: 1.1
|
||||
- julia_version: 1.2
|
||||
- julia_version: 1.3
|
||||
platform:
|
||||
- x64
|
||||
- x86
|
||||
matrix:
|
||||
allow_failures:
|
||||
- julia_version: 1.3
|
||||
branches:
|
||||
only:
|
||||
- master
|
||||
|
@ -11,6 +11,7 @@ jobs:
|
||||
version:
|
||||
- '1.0'
|
||||
- '1.2'
|
||||
- '1.3'
|
||||
os:
|
||||
- macOS-latest
|
||||
- windows-latest
|
||||
|
2
test/fixtures/WackyOptions/README.md
vendored
2
test/fixtures/WackyOptions/README.md
vendored
@ -1,4 +1,4 @@
|
||||
# WackyOptions [](https://tester.gitlab.io/WackyOptions.jl/dev) [](https://github.com/tester/WackyOptions.jl/workflows/CI/badge.svg) [](https://gitlab.com/tester/WackyOptions.jl/pipelines) [](https://travis-ci.com/tester/WackyOptions.jl) [](https://ci.appveyor.com/project/tester/WackyOptions-jl) [](https://cloud.drone.io/tester/WackyOptions.jl) [](https://cirrus-ci.com/github/tester/WackyOptions.jl) [](https://codecov.io/gh//.jl) [](https://coveralls.io/github//.jl?branch=master)
|
||||
# WackyOptions [](https://tester.gitlab.io/WackyOptions.jl/dev) [](https://github.com/tester/WackyOptions.jl/actions) [](https://gitlab.com/tester/WackyOptions.jl/pipelines) [](https://travis-ci.com/tester/WackyOptions.jl) [](https://ci.appveyor.com/project/tester/WackyOptions-jl) [](https://cloud.drone.io/tester/WackyOptions.jl) [](https://cirrus-ci.com/github/tester/WackyOptions.jl) [](https://codecov.io/gh/tester/WackyOptions.jl) [](https://coveralls.io/github/tester/WackyOptions.jl?branch=master)
|
||||
|
||||
## Citing
|
||||
|
||||
|
15
test/fixtures/WackyOptions/docs/Manifest.toml
vendored
15
test/fixtures/WackyOptions/docs/Manifest.toml
vendored
@ -18,10 +18,10 @@ uuid = "ffbed154-4ef7-542d-bbb7-c09d3a79fcae"
|
||||
version = "0.8.1"
|
||||
|
||||
[[Documenter]]
|
||||
deps = ["Base64", "DocStringExtensions", "InteractiveUtils", "JSON", "LibGit2", "Logging", "Markdown", "REPL", "Test", "Unicode"]
|
||||
git-tree-sha1 = "d45c163c7a3ae293c15361acc52882c0f853f97c"
|
||||
deps = ["Base64", "Dates", "DocStringExtensions", "InteractiveUtils", "JSON", "LibGit2", "Logging", "Markdown", "REPL", "Test", "Unicode"]
|
||||
git-tree-sha1 = "0be9bf63e854a2408c2ecd3c600d68d4d87d8a73"
|
||||
uuid = "e30172f5-a6a5-5a46-863b-614d45cd2de4"
|
||||
version = "0.23.4"
|
||||
version = "0.24.2"
|
||||
|
||||
[[InteractiveUtils]]
|
||||
deps = ["Markdown"]
|
||||
@ -36,6 +36,9 @@ version = "0.21.0"
|
||||
[[LibGit2]]
|
||||
uuid = "76f85450-5226-5b5a-8eaa-529ad045b433"
|
||||
|
||||
[[Libdl]]
|
||||
uuid = "8f399da3-3557-5675-b5ff-fb832c97cbdb"
|
||||
|
||||
[[Logging]]
|
||||
uuid = "56ddb016-857b-54e1-b83d-db4d58db5568"
|
||||
|
||||
@ -48,12 +51,12 @@ uuid = "a63ad114-7e13-5084-954f-fe012c677804"
|
||||
|
||||
[[Parsers]]
|
||||
deps = ["Dates", "Test"]
|
||||
git-tree-sha1 = "c56ecb484f286639f161e712b8311f5ab77e8d32"
|
||||
git-tree-sha1 = "0139ba59ce9bc680e2925aec5b7db79065d60556"
|
||||
uuid = "69de0a69-1ddd-5017-9359-2bf0b02dc9f0"
|
||||
version = "0.3.8"
|
||||
version = "0.3.10"
|
||||
|
||||
[[Pkg]]
|
||||
deps = ["Dates", "LibGit2", "Markdown", "Printf", "REPL", "Random", "SHA", "UUIDs"]
|
||||
deps = ["Dates", "LibGit2", "Libdl", "Logging", "Markdown", "Printf", "REPL", "Random", "SHA", "UUIDs"]
|
||||
uuid = "44cfe95a-1eb2-52ea-b672-e2afdf69b78f"
|
||||
|
||||
[[Printf]]
|
||||
|
@ -1,12 +1,29 @@
|
||||
const STATIC_FILE = joinpath(@__DIR__, "fixtures", "static.txt")
|
||||
const STATIC_DOCUMENTER = [
|
||||
PackageSpec(; name="DocStringExtensions", version=v"0.8.1"),
|
||||
PackageSpec(; name="Documenter", version=v"0.24.2"),
|
||||
PackageSpec(; name="JSON", version=v"0.21.0"),
|
||||
PackageSpec(; name="Parsers", version=v"0.3.10"),
|
||||
]
|
||||
|
||||
PT.user_view(::Citation, ::Template, ::AbstractString) = Dict("MONTH" => 8, "YEAR" => 2019)
|
||||
PT.user_view(::License, ::Template, ::AbstractString) = Dict("YEAR" => 2019)
|
||||
|
||||
function pin_documenter(project_dir::AbstractString)
|
||||
@suppress PT.with_project(project_dir) do
|
||||
foreach(Pkg.add, STATIC_DOCUMENTER)
|
||||
end
|
||||
toml = joinpath(project_dir, "Project.toml")
|
||||
project = TOML.parsefile(toml)
|
||||
filter!(p -> p.first == "Documenter", project["deps"])
|
||||
open(io -> TOML.print(io, project), toml, "w")
|
||||
end
|
||||
|
||||
function test_all(pkg::AbstractString; kwargs...)
|
||||
t = tpl(; kwargs...)
|
||||
with_pkg(t, pkg) do pkg
|
||||
pkg_dir = joinpath(t.dir, pkg)
|
||||
PT.hasplugin(t, Documenter) && pin_documenter(joinpath(pkg_dir, "docs"))
|
||||
foreach(readlines(`git -C $pkg_dir ls-files`)) do f
|
||||
reference = joinpath(@__DIR__, "fixtures", pkg, f)
|
||||
observed = read(joinpath(pkg_dir, f), String)
|
||||
@ -42,7 +59,7 @@ end
|
||||
|
||||
@testset "Wacky options" begin
|
||||
test_all("WackyOptions"; authors=USER, julia=v"1.2", plugins=[
|
||||
AppVeyor(; x86=true, coverage=true, extra_versions=[v"1.3"]),
|
||||
AppVeyor(; x86=true, coverage=true, extra_versions=[v"1.1"]),
|
||||
CirrusCI(; image="freebsd-123", coverage=false, extra_versions=["1.1"]),
|
||||
Citation(; readme=true),
|
||||
Codecov(; file=STATIC_FILE),
|
||||
|
@ -1,7 +1,7 @@
|
||||
using Base.Filesystem: contractuser, path_separator
|
||||
|
||||
using LibGit2: LibGit2, GitCommit, GitRemote, GitRepo
|
||||
using Pkg: Pkg
|
||||
using Pkg: Pkg, PackageSpec, TOML
|
||||
using Random: Random, randstring
|
||||
using Test: @test, @testset, @test_logs, @test_throws
|
||||
|
||||
@ -48,9 +48,9 @@ mktempdir() do dir
|
||||
include("git.jl")
|
||||
|
||||
# Quite a bit of output depends on the Julia version,
|
||||
# and the test fixtures are made with Julia 1.2.
|
||||
# and the test fixtures are made with Julia 1.3.
|
||||
# TODO: Keep this on the latest stable Julia version.
|
||||
if VERSION.major == 1 && VERSION.minor == 2
|
||||
if VERSION.major == 1 && VERSION.minor == 3
|
||||
include("reference.jl")
|
||||
else
|
||||
@info "Skipping reference tests" julia=VERSION
|
||||
|
Loading…
Reference in New Issue
Block a user