Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Appveyor only tests plotting #115

Open
wants to merge 4 commits into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 6 additions & 2 deletions .travis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,11 +2,11 @@
language: julia
julia:
- 1.0 # Latest LTS release
- 1 # Latest stable release
- 1 # Latest stable release
- nightly
os:
- linux
# - windows # Can't use Travis to test windows because https://github.com/JuliaIO/FFMPEG.jl/issues/14
- windows
arch:
- x64
- x86
Expand All @@ -25,6 +25,10 @@ jobs:
- os: windows
arch: x64
include:
# Windows plotting tests fail on Travis CI due to: https://github.com/JuliaIO/FFMPEG.jl/issues/14
# Additionally, the build of FFMPEG.jl will fail but testing will still proceed
- os: windows
env: TESTS="-plotting"
- stage: Documentation
julia: 1.0
script: julia --project=docs -e '
Expand Down
9 changes: 5 additions & 4 deletions appveyor.yml
Original file line number Diff line number Diff line change
@@ -1,11 +1,12 @@
environment:
TESTS: plotting # Limit Appveyor testing to just plotting as Travis is faster
matrix:
- julia_version: 1.0 # latest LTS
- julia_version: 1 # latest stable
- julia_version: nightly
- julia_version: 1.0 # Latest LTS
- julia_version: 1 # Latest stable
- julia_version: nightly

platform:
- x64 # 64-bit
- x64 # 64-bit

matrix:
allow_failures:
Expand Down
39 changes: 31 additions & 8 deletions test/runtests.jl
Original file line number Diff line number Diff line change
Expand Up @@ -7,13 +7,36 @@ using TimeZones

const BOUND_PERMUTATIONS = product((Closed, Open), (Closed, Open))

@testset "Intervals" begin
include("inclusivity.jl")
include("endpoint.jl")
include("interval.jl")
include("anchoredinterval.jl")
include("comparisons.jl")
include("plotting.jl")
const ALL_TESTS = (
:inclusivity,
:endpoint,
:interval,
:anchoredinterval,
:comparisons,
:plotting,
:doctest,
)

const TESTS = let
# e.g. `TESTS="interval comparisons"` or `TEST="-plotting"`
tests = split(get(ENV, "TESTS", ""), r"\s+", keepempty=false)

doctest(Intervals)
isexclude(x) = startswith(x, '-')
includes = Symbol.(filter(!isexclude, tests))
excludes = Symbol.(replace.(filter(isexclude, tests), Ref(r"^-" => "")))

isempty(includes) && (includes = ALL_TESTS)
setdiff(includes, excludes)
end

@show get(ENV, "TESTS", "") TESTS

@testset "Intervals" begin
:inclusivity in TESTS && include("inclusivity.jl")
:endpoint in TESTS && include("endpoint.jl")
:interval in TESTS && include("interval.jl")
:anchoredinterval in TESTS && include("anchoredinterval.jl")
:comparisons in TESTS && include("comparisons.jl")
:plotting in TESTS && include("plotting.jl")
:doctest in TESTS && doctest(Intervals)
end