Web   ·   Wiki   ·   Activities   ·   Blog   ·   Lists   ·   Chat   ·   Meeting   ·   Bugs   ·   Git   ·   Translate   ·   Archive   ·   People   ·   Donate
summaryrefslogtreecommitdiffstats
path: root/test
diff options
context:
space:
mode:
authorNickolay V. Shmyrev <nshmyrev@yandex.ru>2008-09-07 16:27:14 (GMT)
committer Nickolay V. Shmyrev <nshmyrev@src.gnome.org>2008-09-07 16:27:14 (GMT)
commitcfe4ba6711c12ea9ad1ddba4cbd60e964715170b (patch)
tree6efd3a235a74e8c092dfa1e96d5831d1b8595b10 /test
parentc8ff46f7c9444ea484ac85b5a8a68d0905acad84 (diff)
Patch for case unsensitive page label match by Michael Lee. See bug
2008-09-07 Nickolay V. Shmyrev <nshmyrev@yandex.ru> * shell/ev-page-cache.c (ev_page_cache_set_page_label): Patch for case unsensitive page label match by Michael Lee. See bug #550136. * shell/ev-page-action.c (create_tool_item): * test/Makefile.am: * test/test1.py: * test/test4.py: * test/test5.py: Added test for the above and updated other tests. svn path=/trunk/; revision=3161
Diffstat (limited to 'test')
-rw-r--r--test/Makefile.am13
-rw-r--r--test/test-page-labels.pdfbin0 -> 10150 bytes
-rwxr-xr-xtest/test1.py2
-rwxr-xr-xtest/test4.py7
-rwxr-xr-xtest/test5.py24
5 files changed, 40 insertions, 6 deletions
diff --git a/test/Makefile.am b/test/Makefile.am
index db56b57..aa562d3 100644
--- a/test/Makefile.am
+++ b/test/Makefile.am
@@ -1,6 +1,15 @@
-dist_check_SCRIPTS = test1.py test2.py test3.py test4.py
+dist_check_SCRIPTS = \
+ test1.py \
+ test2.py \
+ test3.py \
+ test4.py \
+ test5.py
TESTS = $(dist_check_SCRIPTS)
-EXTRA_DIST = test-encrypt.pdf test-links.pdf test-mime.bin
+EXTRA_DIST = \
+ test-encrypt.pdf \
+ test-links.pdf \
+ test-mime.bin \
+ test-page-labels.pdf
diff --git a/test/test-page-labels.pdf b/test/test-page-labels.pdf
new file mode 100644
index 0000000..c7d1267
--- /dev/null
+++ b/test/test-page-labels.pdf
Binary files differ
diff --git a/test/test1.py b/test/test1.py
index 6822c7f..a106c0d 100755
--- a/test/test1.py
+++ b/test/test1.py
@@ -24,7 +24,7 @@ click('Close', roleName='push button')
# About dialog
click('Help', roleName='menu')
click('About', roleName='menu item')
-focus.dialog('About Evince')
+focus.dialog('About Document Viewer')
click('Credits', roleName='push button')
focus.dialog('Credits')
click('Close', roleName='push button')
diff --git a/test/test4.py b/test/test4.py
index 86ff197..789030e 100755
--- a/test/test4.py
+++ b/test/test4.py
@@ -10,9 +10,10 @@ from dogtail.procedural import *
run('evince', arguments=' '+srcdir+'/test-links.pdf')
-# Close evince
-click('View', roleName='menu')
-click('Reload', roleName='menu item')
+# Reload document a few times
+for i in range(1,6):
+ click('View', roleName='menu')
+ click('Reload', roleName='menu item')
# Close evince
click('File', roleName='menu')
diff --git a/test/test5.py b/test/test5.py
new file mode 100755
index 0000000..9fd7276
--- /dev/null
+++ b/test/test5.py
@@ -0,0 +1,24 @@
+#!/usr/bin/python
+
+# This test tries document reload action.
+
+import os
+os.environ['LANG']='C'
+srcdir = os.environ['srcdir']
+
+from dogtail.procedural import *
+
+run('evince', arguments=' '+srcdir+'/test-page-labels.pdf')
+
+focus.widget('page-label-entry')
+focus.widget.text = "iii"
+activate()
+
+if focus.widget.text != "III":
+ click('File', roleName='menu')
+ click('Close', roleName='menu item')
+ exit (1)
+
+# Close evince
+click('File', roleName='menu')
+click('Close', roleName='menu item')