Skip to content

Commit c56c879

Browse files
Fix deprecations
1 parent b8bfd6e commit c56c879

File tree

2 files changed

+1
-31
lines changed

2 files changed

+1
-31
lines changed

test/b-splines/mixed.jl

Lines changed: 1 addition & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -28,11 +28,7 @@ for (constructor, copier) in ((interpolate, x->x), (interpolate!, copy))
2828
end
2929

3030
# AbstractArrays
31-
if VERSION < v"0.5.0"
32-
makesharedarray{T}(::Type{T}, dims; kwargs...) = SharedArray(T, dims; kwargs...)
33-
else
34-
makesharedarray{T}(::Type{T}, dims; kwargs...) = SharedArray{T}(dims; kwargs...)
35-
end
31+
makesharedarray{T}(::Type{T}, dims; kwargs...) = SharedArray{T}(dims; kwargs...)
3632
function copyshared(A)
3733
B = makesharedarray(eltype(A), size(A))
3834
copy!(B, A)

test/scaling/nointerp.jl

Lines changed: 0 additions & 26 deletions
Original file line numberDiff line numberDiff line change
@@ -21,31 +21,5 @@ end
2121

2222
@test length(gradient(sitp, pi/3, 2)) == 1
2323

24-
if VERSION < v"0.5.0-dev" # Test.with_handler was removed in 0.5
25-
26-
# Test error messages for incorrect initialization
27-
function message_is(message)
28-
r -> r.err.msg == message || error("Incorrect error message: expected '$message' but was '$(r.err.msg)'")
29-
end
30-
Test.with_handler(message_is("Must scale 2-dimensional interpolation object with exactly 2 ranges (you used 1)")) do
31-
@test scale(itp, xs)
32-
end
33-
Test.with_handler(message_is("NoInterp dimension 2 must be scaled with unit range 1:3")) do
34-
@test scale(itp, xs, -1:1)
35-
end
36-
Test.with_handler(message_is("The length of the range in dimension 1 (8) did not equal the size of the interpolation object in that direction (11)")) do
37-
@test scale(itp, -pi:2pi/7:pi, 1:3)
38-
end
39-
Test.with_handler(message_is("Must index into 2-dimensional scaled interpolation object with exactly 2 indices (you used 1)")) do
40-
@test sitp[2.3]
41-
end
42-
Test.with_handler(message_is("Must index into 2-dimensional scaled interpolation object with exactly 2 indices (you used 1)")) do
43-
@test gradient(sitp, 2.3)
44-
end
45-
Test.with_handler(message_is("The length of the provided gradient vector (2) did not match the number of interpolating dimensions (1)")) do
46-
@test gradient!(Array{Float64}( 2), sitp, 2.3, 2)
47-
end
48-
49-
end
5024

5125
end

0 commit comments

Comments
 (0)