Skip to content

Commit 368c5f6

Browse files
committed
Add tests
1 parent d737252 commit 368c5f6

1 file changed

Lines changed: 18 additions & 0 deletions

File tree

spec/reference_spec.cr

Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -866,12 +866,30 @@ describe "Julia reference output compatibility" do
866866
test_ref("heatmap/default_0x0.txt", p)
867867
end
868868

869+
it "matches heatmap/default_0x5" do
870+
z = [] of Array(Float64)
871+
p = UnicodePlot.heatmap(z, labels: false, xlim: {1.0, 5.0})
872+
test_ref("heatmap/default_0x5.txt", p)
873+
end
874+
875+
it "matches heatmap/default_0x10" do
876+
z = [] of Array(Float64)
877+
p = UnicodePlot.heatmap(z, labels: false, xlim: {1.0, 10.0})
878+
test_ref("heatmap/default_0x10.txt", p)
879+
end
880+
869881
it "matches heatmap/default_5x0" do
870882
z = Array.new(5) { [] of Float64 }
871883
p = UnicodePlot.heatmap(z, labels: false)
872884
test_ref("heatmap/default_5x0.txt", p)
873885
end
874886

887+
it "matches heatmap/default_10x0" do
888+
z = Array.new(10) { [] of Float64 }
889+
p = UnicodePlot.heatmap(z, labels: false)
890+
test_ref("heatmap/default_10x0.txt", p)
891+
end
892+
875893
# integers_20x20: repeat(collect(1:20), outer=(1,20)) → A[i,j] = i
876894
it "matches heatmap/integers_20x20" do
877895
z = Array.new(20) { |i| Array.new(20) { |_j| (i + 1).to_f } }

0 commit comments

Comments
 (0)