]> www.fi.muni.cz Git - evince.git/commitdiff
Fixes the test
authorNickolay V. Shmyrev <nshmyrev@src.gnome.org>
Wed, 15 Apr 2009 20:35:03 +0000 (20:35 +0000)
committerNickolay V. Shmyrev <nshmyrev@src.gnome.org>
Wed, 15 Apr 2009 20:35:03 +0000 (20:35 +0000)
svn path=/trunk/; revision=3612

test/test6.py

index 9ffcfaec78b11a5b51644f344c78c87cbb64ee62..89b6e5d0246ce1215a861caf6ea5b076ad206960 100755 (executable)
@@ -5,10 +5,12 @@
 import os
 os.environ['LANG']='C'
 srcdir = os.environ['srcdir']
+homedir = os.environ["HOME"] + "/";
 
 from dogtail.procedural import *
 
-os.unlink("output.ps")
+if os.path.exists(homedir + "output.ps"):
+    os.unlink(homedir + "output.ps")
 
 run('evince', arguments=' '+srcdir+'/test-page-labels.pdf')
 
@@ -19,10 +21,10 @@ focus.dialog('Print')
 click('Print to File', roleName='table cell', raw=True)
 click('Print', roleName='push button')
 
-statinfo = os.stat ("output.ps")
+statinfo = os.stat (homedir + "output.ps")
 if statinfo.st_size > 100000:
     exit(1)
-os.unlink ("output.ps")
+os.unlink (homedir + "output.ps")
 
 # Close evince
 click('File', roleName='menu')