[testinggtk] Attempts to create zero-size pixbufs should raise RuntimeError.
- From: Björn Lindqvist <bjornl src gnome org>
- To: svn-commits-list gnome org
- Subject: [testinggtk] Attempts to create zero-size pixbufs should raise RuntimeError.
- Date: Sat, 6 Jun 2009 16:21:11 -0400 (EDT)
commit d16c9e351f9b4f0a52c2f2c518657114e3955220
Author: Björn Lindqvist <bjourne gmail com>
Date: Sat Jun 6 22:17:43 2009 +0200
Attempts to create zero-size pixbufs should raise RuntimeError.
---
tests/gdk/test_pixbuf.py | 12 ++++++++++++
1 files changed, 12 insertions(+), 0 deletions(-)
diff --git a/tests/gdk/test_pixbuf.py b/tests/gdk/test_pixbuf.py
index a60e430..1d73335 100644
--- a/tests/gdk/test_pixbuf.py
+++ b/tests/gdk/test_pixbuf.py
@@ -69,3 +69,15 @@ def test_save_to_callback_options_wrong():
except TypeError:
assert True
+def test_new_from_data_zero_size():
+ '''
+ Attempts to create zero-size pixbufs should raise RuntimeError.
+
+ :bug: #584769
+ '''
+ try:
+ gdk.pixbuf_new_from_data('', gdk.COLORSPACE_RGB, False, 8, 0, 0, 0)
+ assert False
+ except RuntimeError:
+ assert True
+
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]