summaryrefslogtreecommitdiffstats
path: root/tests/testconversion.py
diff options
context:
space:
mode:
authorJohan Dahlin <jdahlin@src.gnome.org>2004-07-10 16:56:36 +0000
committerJohan Dahlin <jdahlin@src.gnome.org>2004-07-10 16:56:36 +0000
commit8238d9cc0fce600328f50efa139db1f575058ae8 (patch)
tree945ced41b87cdff3fd2ac2cb34b84d96f54ae2db /tests/testconversion.py
parentd47520065b91d4f2b9f7e4a53faf008adc780113 (diff)
downloadpygobject-8238d9cc0fce600328f50efa139db1f575058ae8.tar.gz
pygobject-8238d9cc0fce600328f50efa139db1f575058ae8.tar.xz
pygobject-8238d9cc0fce600328f50efa139db1f575058ae8.zip
New script to run all tests in one take
* tests/runtests.py: New script to run all tests in one take * tests/Makefile.am: autotoolify * tests/signal.py: New simple test taken from examples/gobject/signal.py
Diffstat (limited to 'tests/testconversion.py')
-rw-r--r--tests/testconversion.py47
1 files changed, 0 insertions, 47 deletions
diff --git a/tests/testconversion.py b/tests/testconversion.py
deleted file mode 100644
index 22debdc..0000000
--- a/tests/testconversion.py
+++ /dev/null
@@ -1,47 +0,0 @@
-# -*- Mode: Python; py-indent-offset: 4 -*-
-
-import unittest
-import testsupport
-
-import gtk
-
-class Tests(unittest.TestCase):
-
- def testUnicharArg(self):
- """ Test unichar values when used as arguments. """
-
- entry = gtk.Entry()
- for valid_value in ['a', u'b', u'\ufff0', u'\ufff0'.encode()]:
- entry.set_invisible_char(valid_value)
- assert entry.get_invisible_char() == unicode(valid_value)
-
- for invalid_value in ['12', None, 1, '']:
- try:
- entry.set_invisible_char(invalid_value)
- except:
- pass
- else:
- raise AssertionError('exception not raised on invalid value w/ set_invisible_char: %s'
- % invalid_value)
-
- def testUnicharProperty(self):
- """ Test unichar values when used as properties. """
-
- entry = gtk.Entry()
- for valid_value in ['a', u'b', u'\ufff0', u'\ufff0'.encode()]:
- entry.set_property('invisible_char', valid_value)
- assert entry.get_property('invisible_char') == valid_value
-
- for invalid_value in ['12', None, 1, '']:
- try:
- entry.set_property('invisible_char', invalid_value)
- except:
- pass
- else:
- raise AssertionError('exception not raised on invalid value w/ set_property: %s'
- % invalid_value)
-def main():
- testsupport.run_all_tests()
-
-if __name__ == '__main__':
- main() \ No newline at end of file