From 2b5c3d12f77156a50d165d81d99bc57737f7865d Mon Sep 17 00:00:00 2001 From: Chris Rackauckas Date: Mon, 23 Dec 2019 01:25:45 -0500 Subject: [PATCH 1/3] Make the NNlib tests more robust --- .travis.yml | 6 ++-- Manifest.toml | 89 ------------------------------------------------ Project.toml | 6 ++-- test/runtests.jl | 25 +++++++++++--- 4 files changed, 28 insertions(+), 98 deletions(-) delete mode 100644 Manifest.toml diff --git a/.travis.yml b/.travis.yml index 87a3e9ff5..c8549f170 100644 --- a/.travis.yml +++ b/.travis.yml @@ -5,7 +5,7 @@ os: - osx julia: - 1.0 - - 1.1 + - 1 - nightly matrix: allow_failures: @@ -16,7 +16,9 @@ git: depth: 99999999 env: # Disable test fuzzing for the moment, as we're a little too slow for Travis - - NNLIB_TEST_FUZZING=false + - GROUP=Core + - NNLIB_TEST_FUZZING=false + - GROUP=Downstream # Submit to Codecov after_success: diff --git a/Manifest.toml b/Manifest.toml deleted file mode 100644 index a956fab85..000000000 --- a/Manifest.toml +++ /dev/null @@ -1,89 +0,0 @@ -# This file is machine-generated - editing it directly is not advised - -[[Base64]] -uuid = "2a0f44e3-6c83-55bd-87e4-b1978d98bd5f" - -[[BinaryProvider]] -deps = ["Libdl", "Pkg", "SHA", "Test"] -git-tree-sha1 = "055eb2690182ebc31087859c3dd8598371d3ef9e" -uuid = "b99e7846-7c00-51b0-8f62-c81ae34c0232" -version = "0.5.3" - -[[Dates]] -deps = ["Printf"] -uuid = "ade2ca70-3891-5945-98fb-dc099432e06a" - -[[Distributed]] -deps = ["Random", "Serialization", "Sockets"] -uuid = "8ba89e20-285c-5b6f-9357-94700520ee1b" - -[[InteractiveUtils]] -deps = ["Markdown"] -uuid = "b77e0a4c-d291-57a0-90e8-8db25a27a240" - -[[LibGit2]] -uuid = "76f85450-5226-5b5a-8eaa-529ad045b433" - -[[Libdl]] -uuid = "8f399da3-3557-5675-b5ff-fb832c97cbdb" - -[[LinearAlgebra]] -deps = ["Libdl"] -uuid = "37e2e46d-f89d-539d-b4ee-838fcccc9c8e" - -[[Logging]] -uuid = "56ddb016-857b-54e1-b83d-db4d58db5568" - -[[Markdown]] -deps = ["Base64"] -uuid = "d6f4376e-aef5-505a-96c1-9c027394607a" - -[[Pkg]] -deps = ["Dates", "LibGit2", "Markdown", "Printf", "REPL", "Random", "SHA", "UUIDs"] -uuid = "44cfe95a-1eb2-52ea-b672-e2afdf69b78f" - -[[Printf]] -deps = ["Unicode"] -uuid = "de0858da-6303-5e67-8744-51eddeeeb8d7" - -[[REPL]] -deps = ["InteractiveUtils", "Markdown", "Sockets"] -uuid = "3fa0cd96-eef1-5676-8a61-b3b8758bbffb" - -[[Random]] -deps = ["Serialization"] -uuid = "9a3f8284-a2c9-5f02-9a11-845980a1fd5c" - -[[Requires]] -deps = ["Test"] -git-tree-sha1 = "f6fbf4ba64d295e146e49e021207993b6b48c7d1" -uuid = "ae029012-a4dd-5104-9daa-d747884805df" -version = "0.5.2" - -[[SHA]] -uuid = "ea8e919c-243c-51af-8825-aaa63cd721ce" - -[[Serialization]] -uuid = "9e88b42a-f829-5b0c-bbe9-9e923198166b" - -[[Sockets]] -uuid = "6462fe0b-24de-5631-8697-dd941f90decc" - -[[SparseArrays]] -deps = ["LinearAlgebra", "Random"] -uuid = "2f01184e-e22b-5df5-ae63-d93ebab69eaf" - -[[Statistics]] -deps = ["LinearAlgebra", "SparseArrays"] -uuid = "10745b16-79ce-11e8-11f9-7d13ad32a3b2" - -[[Test]] -deps = ["Distributed", "InteractiveUtils", "Logging", "Random"] -uuid = "8dfed614-e22c-5e08-85e1-65c5234f0b40" - -[[UUIDs]] -deps = ["Random", "SHA"] -uuid = "cf7118a7-6976-5b1a-9a39-7adc72f591a4" - -[[Unicode]] -uuid = "4ec0a83e-493e-50e2-b9ac-8f72acf5a8f5" diff --git a/Project.toml b/Project.toml index 755d266ca..6e1aa50f2 100644 --- a/Project.toml +++ b/Project.toml @@ -10,12 +10,14 @@ Requires = "ae029012-a4dd-5104-9daa-d747884805df" Statistics = "10745b16-79ce-11e8-11f9-7d13ad32a3b2" [compat] -julia = "1" BinaryProvider = "0.5" Requires = "0.5, 1.0" +julia = "1" [extras] +Pkg = "44cfe95a-1eb2-52ea-b672-e2afdf69b78f" +SafeTestsets = "1bc83da4-3b8d-516f-aca4-4fe02f6d838f" Test = "8dfed614-e22c-5e08-85e1-65c5234f0b40" [targets] -test = ["Test"] +test = ["Pkg", "SafeTestsets", "Test"] diff --git a/test/runtests.jl b/test/runtests.jl index dacb7ac54..ab3b915c2 100644 --- a/test/runtests.jl +++ b/test/runtests.jl @@ -1,6 +1,21 @@ -using NNlib, Test +using SafeTestsets -include("activation.jl") -include("conv.jl") -include("pooling.jl") -include("inference.jl") +const GROUP = get(ENV, "GROUP", "All") +const is_APPVEYOR = Sys.iswindows() && haskey(ENV,"APPVEYOR") +const is_TRAVIS = haskey(ENV,"TRAVIS") + +@time begin +if GROUP == "All" || GROUP == "Core" + @safetestset "Activation Functions" begin include("activation.jl") end + @safetestset "Convolutions" begin include("conv.jl") end + @safetestset "Pooling Functions" begin include("pooling.jl") end + @safetestset "Inference" begin include("inference.jl") end +end + +if GROUP == "Downstream" + if is_TRAVIS + using Pkg + Pkg.add("Flux") + end + Pkg.test("Flux") +end From 5ca5eea160004d178c4a09e307cb7d8518b3ca48 Mon Sep 17 00:00:00 2001 From: Chris Rackauckas Date: Mon, 23 Dec 2019 01:31:55 -0500 Subject: [PATCH 2/3] typo and ignore Manifest --- .gitignore | 1 + test/runtests.jl | 11 ++++++----- 2 files changed, 7 insertions(+), 5 deletions(-) diff --git a/.gitignore b/.gitignore index 42cde8160..b4726d8d1 100644 --- a/.gitignore +++ b/.gitignore @@ -10,3 +10,4 @@ deps/usr deps.jl *.log +Manifest.toml diff --git a/test/runtests.jl b/test/runtests.jl index ab3b915c2..31e3a0d69 100644 --- a/test/runtests.jl +++ b/test/runtests.jl @@ -5,11 +5,12 @@ const is_APPVEYOR = Sys.iswindows() && haskey(ENV,"APPVEYOR") const is_TRAVIS = haskey(ENV,"TRAVIS") @time begin -if GROUP == "All" || GROUP == "Core" - @safetestset "Activation Functions" begin include("activation.jl") end - @safetestset "Convolutions" begin include("conv.jl") end - @safetestset "Pooling Functions" begin include("pooling.jl") end - @safetestset "Inference" begin include("inference.jl") end + if GROUP == "All" || GROUP == "Core" + @safetestset "Activation Functions" begin include("activation.jl") end + @safetestset "Convolutions" begin include("conv.jl") end + @safetestset "Pooling Functions" begin include("pooling.jl") end + @safetestset "Inference" begin include("inference.jl") end + end end if GROUP == "Downstream" From 14868c56389b0e50bb39d2915b4c777f976c5676 Mon Sep 17 00:00:00 2001 From: Christopher Rackauckas Date: Mon, 23 Dec 2019 19:45:28 -0500 Subject: [PATCH 3/3] Update .travis.yml --- .travis.yml | 2 ++ 1 file changed, 2 insertions(+) diff --git a/.travis.yml b/.travis.yml index c8549f170..4fc3f7b3f 100644 --- a/.travis.yml +++ b/.travis.yml @@ -5,6 +5,8 @@ os: - osx julia: - 1.0 + - 1.1 + - 1.2 - 1 - nightly matrix: