forked from JuliaML/MLDatasets.jl
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathruntests.jl
64 lines (54 loc) · 1.45 KB
/
runtests.jl
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
using Test
using MLDatasets
using MLDatasets: SupervisedDataset, UnsupervisedDataset, AbstractDataset
using MLDatasets: Graph
using DataFrames, Tables, CSV
using ImageShow
using ColorTypes
using FixedPointNumbers
using JSON3
using Pickle
ENV["DATADEPS_ALWAYS_ACCEPT"] = true
include("test_utils.jl")
dataset_tests = [
"datasets/graphs.jl",
"datasets/misc.jl",
"datasets/text.jl",
"datasets/vision/fashion_mnist.jl",
"datasets/vision/mnist.jl",
]
no_ci_dataset_tests = [
"datasets/graphs_no_ci.jl",
"datasets/text_no_ci.jl",
"datasets/vision/cifar10.jl",
"datasets/vision/cifar100.jl",
"datasets/vision/emnist.jl",
"datasets/vision/omniglot.jl",
"datasets/vision/svhn2.jl",
"datasets/meshes.jl",
]
@assert isempty(intersect(dataset_tests, no_ci_dataset_tests))
container_tests = [
"containers/filedataset.jl",
# "containers/tabledataset.jl",
# "containers/hdf5dataset.jl",
# "containers/jld2dataset.jl",
"containers/cacheddataset.jl",
]
@testset "Datasets" begin
@testset "$(split(t,"/")[end])" for t in dataset_tests
include(t)
end
if !parse(Bool, get(ENV, "CI", "false"))
@info "Testing larger datasets"
@testset "$(split(t,"/")[end])" for t in no_ci_dataset_tests
include(t)
end
else
@info "CI detected: skipping tests on large datasets"
end
end
@testset "Containers" begin for t in container_tests
include(t)
end end
nothing