Skip to content

Commit 3b7a2df

Browse files
authored
Fix @test_broken problems (#546)
* Fix `@test_broken` problems * Correct remaining tests * Bump version
1 parent e5696d7 commit 3b7a2df

File tree

5 files changed

+39
-12
lines changed

5 files changed

+39
-12
lines changed

Project.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
name = "KernelFunctions"
22
uuid = "ec8451be-7e33-11e9-00cf-bbf324bd1392"
3-
version = "0.10.60"
3+
version = "0.10.61"
44

55
[deps]
66
ChainRulesCore = "d360d2e6-b24c-11e9-a2a3-2a2ae2dbcce4"

test/basekernels/periodic.jl

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,6 +16,7 @@
1616
TestUtils.test_interface(PeriodicKernel(; r=[0.8, 0.7]), RowVecs{Float64})
1717

1818
# test_ADs(r->PeriodicKernel(r =exp.(r)), log.(r), ADs = [:ForwardDiff, :ReverseDiff])
19-
@test_broken "Undefined adjoint for Sinus metric, and failing randomly for ForwardDiff and ReverseDiff"
19+
# Undefined adjoint for Sinus metric, and failing randomly for ForwardDiff and ReverseDiff
20+
@test_broken false
2021
test_params(k, (r,))
2122
end

test/basekernels/sm.jl

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -57,5 +57,6 @@
5757
end
5858

5959
# test_ADs(x->spectral_mixture_kernel(exp.(x[1:3]), reshape(x[4:18], 5, 3), reshape(x[19:end], 5, 3)), vcat(log.(αs₁), γs[:], ωs[:]), dims = [5,5])
60-
@test_broken "No tests passing (BaseKernel)"
60+
# No tests passing (BaseKernel)
61+
@test_broken false
6162
end

test/basekernels/wiener.jl

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -44,5 +44,6 @@
4444
TestUtils.test_interface(k2, x0, x1, x2)
4545
TestUtils.test_interface(k3, x0, x1, x2)
4646
# test_ADs(()->WienerKernel(i=1))
47-
@test_broken "No tests passing"
47+
# No tests passing
48+
@test_broken false
4849
end

test/transform/selecttransform.jl

Lines changed: 32 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -104,17 +104,41 @@
104104
end
105105

106106
@testset "$(AD)" for AD in [:ReverseDiff]
107-
@test_broken ga = gradient(AD, A) do a
108-
testfunction(ta_row, a, 2)
107+
@test_broken let
108+
gx = gradient(AD, X) do x
109+
testfunction(tx_row, x, 2)
110+
end
111+
ga = gradient(AD, A) do a
112+
testfunction(ta_row, a, 2)
113+
end
114+
gx ga
109115
end
110-
@test_broken ga = gradient(AD, A) do a
111-
testfunction(ta_col, a, 1)
116+
@test_broken let
117+
gx = gradient(AD, X) do x
118+
testfunction(tx_col, x, 1)
119+
end
120+
ga = gradient(AD, A) do a
121+
testfunction(ta_col, a, 1)
122+
end
123+
gx ga
112124
end
113-
@test_broken ga = gradient(AD, A) do a
114-
testfunction(ta_row, a, B, 2)
125+
@test_broken let
126+
gx = gradient(AD, X) do x
127+
testfunction(tx_row, x, Y, 2)
128+
end
129+
ga = gradient(AD, A) do a
130+
testfunction(ta_row, a, B, 2)
131+
end
132+
gx ga
115133
end
116-
@test_broken ga = gradient(AD, A) do a
117-
testfunction(ta_col, a, C, 1)
134+
@test_broken let
135+
gx = gradient(AD, X) do x
136+
testfunction(tx_col, x, Z, 1)
137+
end
138+
ga = gradient(AD, A) do a
139+
testfunction(ta_col, a, C, 1)
140+
end
141+
gx ga
118142
end
119143
end
120144

0 commit comments

Comments
 (0)