Add grid tests for lineplot

This commit is contained in:
kojix2 2021-01-22 11:23:18 +09:00
parent f18c72228c
commit b165de43ed
2 changed files with 28 additions and 2 deletions

View File

@ -0,0 +1,18 @@
┌────────────────────────────────────────┐
50 │⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⢸│
│⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⡄⠀⠀⠀⠀⠀⠀⠀⡸│
│⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⢸⢇⠀⠀⠀⠀⠀⠀⠀⡇│
│⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⢠⢇⠀⠀⠀⠀⠀⠀⠀⡎⢸⠀⠀⠀⠀⠀⠀⢠⠃│
│⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⡄⠀⠀⠀⠀⠀⠀⠀⡜⢸⠀⠀⠀⠀⠀⠀⢠⠃⠈⡆⠀⠀⠀⠀⠀⢸⠀│
│⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⡸⠸⡀⠀⠀⠀⠀⠀⢠⠃⠀⡇⠀⠀⠀⠀⠀⢸⠀⠀⢇⠀⠀⠀⠀⠀⡎⠀│
│⠀⠀⠀⡠⠳⡀⠀⠀⠀⠀⠀⢠⠃⠀⢣⠀⠀⠀⠀⠀⡜⠀⠀⢱⠀⠀⠀⠀⠀⡇⠀⠀⢸⠀⠀⠀⠀⠀⡇⠀│
│⠀⢀⠜⠀⠀⠱⡀⠀⠀⠀⢀⠇⠀⠀⠘⡄⠀⠀⠀⢠⠃⠀⠀⠈⡆⠀⠀⠀⢰⠁⠀⠀⠈⡆⠀⠀⠀⢸⠀⠀│
│⡠⠃⠀⠀⠀⠀⠱⡀⠀⠀⡜⠀⠀⠀⠀⢱⠀⠀⠀⡸⠀⠀⠀⠀⢣⠀⠀⠀⡸⠀⠀⠀⠀⡇⠀⠀⠀⡜⠀⠀│
│⠁⠀⠀⠀⠀⠀⠀⠱⡀⡰⠁⠀⠀⠀⠀⠀⡇⠀⢀⠇⠀⠀⠀⠀⠸⡀⠀⠀⡇⠀⠀⠀⠀⢸⠀⠀⠀⡇⠀⠀│
│⠀⠀⠀⠀⠀⠀⠀⠀⠱⠃⠀⠀⠀⠀⠀⠀⠸⡀⡸⠀⠀⠀⠀⠀⠀⢇⠀⢸⠀⠀⠀⠀⠀⠘⡄⠀⢰⠁⠀⠀│
│⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⢇⠇⠀⠀⠀⠀⠀⠀⢸⠀⡎⠀⠀⠀⠀⠀⠀⡇⠀⢸⠀⠀⠀│
│⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠈⠀⠀⠀⠀⠀⠀⠀⠀⣇⠇⠀⠀⠀⠀⠀⠀⢸⠀⡇⠀⠀⠀│
│⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠹⠀⠀⠀⠀⠀⠀⠀⠘⣄⠇⠀⠀⠀│
-50 │⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⣿⠀⠀⠀⠀│
└────────────────────────────────────────┘
1 10

View File

@ -254,10 +254,18 @@ class YouPlotSimpleTest < Test::Unit::TestCase
end
test :xlim_and_ylim do
test :line_xlim_and_ylim do
YouPlot::Command.new(['line', '--xlim', '-1,5', '--ylim', '-25,50']).run
assert_equal fixture('simple-lineplot-xlim--1-5-ylim--25-50.txt'), @stderr_file.read
end
test :line_grid do
YouPlot::Command.new(['line', '--grid']).run
assert_equal fixture('simple-lineplot.txt'), @stderr_file.read
end
test :line_no_grid do
YouPlot::Command.new(['line', '--no-grid']).run
assert_equal fixture('simple-lineplot-no-grid.txt'), @stderr_file.read
end
end