From 10e044aeda8e816a8786c30a6aeed44da974c3db Mon Sep 17 00:00:00 2001 From: Fabian Greimel <6280307+greimel@users.noreply.github.com> Date: Fri, 20 Sep 2019 09:42:12 +0200 Subject: [PATCH] Apply suggestions from code review Co-Authored-By: Milan Bouchet-Valat --- src/extras.jl | 1 - test/15_extras.jl | 2 +- 2 files changed, 1 insertion(+), 2 deletions(-) diff --git a/src/extras.jl b/src/extras.jl index e06b538b..dc3d83eb 100644 --- a/src/extras.jl +++ b/src/extras.jl @@ -121,7 +121,6 @@ function cut(x::AbstractArray{T, N}, breaks::AbstractVector; extend::Bool=false, labels::Union{AbstractVector{<:AbstractString},Function}=default_formatter, allow_missing::Bool=false) where {T, N} - if !issorted(breaks) breaks = sort(breaks) end diff --git a/test/15_extras.jl b/test/15_extras.jl index d6e98c52..6c2b7692 100644 --- a/test/15_extras.jl +++ b/test/15_extras.jl @@ -108,7 +108,7 @@ end @test levels(x) == ["[2.0, 3.5)", "[3.5, 5.0]"] end -@testset "formatter function" begin +@testset "cut with formatter function" begin my_formatter(from, to, i; closed) = "$i: $from -- $to" x = 0.15:0.20:0.95