]> git.wh0rd.org - fontconfig.git/commitdiff
During test run, remove cache directory to avoid stale cache usage.
authorKeith Packard <keithp@neko.keithp.com>
Mon, 28 Aug 2006 17:30:22 +0000 (10:30 -0700)
committerKeith Packard <keithp@neko.keithp.com>
Mon, 28 Aug 2006 17:30:22 +0000 (10:30 -0700)
As file timestamps have only one second granularity, an old cache
file could easily be used when a test took less than 1 second to run.
Just remove the cache directory and its contents before each test is run.
Also, remove mention of the old cache file from the test config file.

test/fonts.conf.in
test/run-test.sh

index 5ad85c9e3456fb35cb8e79911b005c3dfae779f5..95def72d4207975b5a43748a72e89cdedf22e95f 100644 (file)
@@ -1,5 +1,4 @@
 <fontconfig>
 <dir>@FONTDIR@</dir>
-<cache>@CACHEFILE@</cache>
 <cachedir>@CACHEDIR@</cachedir>
 </fontconfig>
index 8b817c084a39dc21785d7bf01250c35bdeb326a0..e7174b289190c912973a2dd51cf38057f6fcd0a1 100644 (file)
@@ -2,7 +2,6 @@
 TESTDIR=${srcdir-`pwd`}
 
 FONTDIR=`pwd`/fonts
-CACHEFILE=`pwd`/fonts.cache
 CACHEDIR=`pwd`/cache.dir
 
 ECHO=true
@@ -29,7 +28,7 @@ check () {
 }
 
 prep() {
-  rm -rf $CACHEFILE
+  rm -rf $CACHEDIR
   rm -rf $FONTDIR
   mkdir $FONTDIR
 }
@@ -40,7 +39,6 @@ dotest () {
 }
 
 sed "s!@FONTDIR@!$FONTDIR!
-s!@CACHEFILE@!$CACHEFILE!
 s!@CACHEDIR@!$CACHEDIR!" < $TESTDIR/fonts.conf.in > fonts.conf
 
 FONTCONFIG_FILE=`pwd`/fonts.conf