Skip to content

Commit c772768

Browse files
committed
Added two more tests to demo.py
1 parent 9fb3fdf commit c772768

1 file changed

Lines changed: 16 additions & 0 deletions

File tree

demo.py

Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -59,6 +59,22 @@ def check_expected_error(what, f):
5959
gp.plot( np.vstack((-x**3, x**2)), _with='lines' , wait=1)
6060
gp.plot( (np.vstack((x**3, -x**2)), {'with': 'points'} ), wait=1)
6161

62+
# Make sure xrange settings don't get overridden. The label below should be out
63+
# of bounds, and not visible
64+
gp.plot( ( np.arange(10), ),
65+
( np.array((5,),), np.array((2,),), np.array(("Seeing this is a bug!",),),
66+
dict(_with = 'labels',
67+
tuplesize = 3)),
68+
_set = 'yrange [5:10]',
69+
unset = 'grid',
70+
wait = True)
71+
72+
# This should make an empty plot. It should NOT timeout, which is what it's
73+
# doing now
74+
gp.plot( np.arange(10),
75+
_set = 'xrange [10:20]',
76+
wait = True)
77+
6278
#################################
6379
# some more varied plotting, using the object-oriented interface
6480
plot1 = gp.gnuplotlib(_with = 'linespoints',

0 commit comments

Comments
 (0)