]> git.donarmstrong.com Git - lilypond.git/commitdiff
further test fixes: trim git-diff output.
authorHan-Wen Nienhuys <hanwen@xs4all.nl>
Fri, 5 Jan 2007 13:41:21 +0000 (14:41 +0100)
committerHan-Wen Nienhuys <hanwen@xs4all.nl>
Fri, 5 Jan 2007 13:41:21 +0000 (14:41 +0100)
GNUmakefile.in
buildscripts/output-distance.py

index d8b725b7e1403f401d796163c9501fd4a70fb2c2..f51a05b19d471d2835f13ac1a3ffaa8e3a65176b 100644 (file)
@@ -213,8 +213,8 @@ OUT_TEST=test
 
 
 test:
-       rm -f input/regression/out-test/collated-files.html
-       $(MAKE) -C input/regression/ out=$(OUT_TEST) LILYPOND_BOOK_LILYPOND_FLAGS="--backend=eps --formats=ps $(LILYPOND_JOBS) -dseparate-log-files -dinclude-eps-fonts -dgs-load-fonts --header=texidoc -I $(top-src-dir)/input/manual -ddump-profile -dcheck-internal-types -ddump-signatures -danti-alias-factor=1" LILYPOND_BOOK_VERBOSE= out-test/collated-files.html 
+       rm -f input/regression/out-$(OUT_TEST)/collated-files.html
+       $(MAKE) -C input/regression/ out=$(OUT_TEST) LILYPOND_BOOK_LILYPOND_FLAGS="--backend=eps --formats=ps $(LILYPOND_JOBS) -dseparate-log-files -dinclude-eps-fonts -dgs-load-fonts --header=texidoc -I $(top-src-dir)/input/manual -ddump-profile -dcheck-internal-types -ddump-signatures -danti-alias-factor=1" LILYPOND_BOOK_VERBOSE= out-$(OUT_TEST)/collated-files.html 
        @find input ly -name '*.ly' -print |grep -v 'out.*/' | xargs grep '\\version' -L | grep -v "standard input" |sed 's/^/**** Missing version: /g' 
        if test -d .git  ; then \
                echo -e 'HEAD is:\n\n\t' ; \
index 8939ab27b2f31fe990d86a6d9e06feb878a415c5..5aa5dfcb6e0f4d292c14bce9be1cf1cb1b13fe1a 100644 (file)
@@ -439,7 +439,14 @@ class FileCompareLink (FileLink):
 
 class GitFileCompareLink (FileCompareLink):
     def get_cell (self, oldnew):
-        return self.contents[oldnew]
+        str = self.contents[oldnew]
+
+        # truncate long lines
+        str = '\n'.join ([l[:80] for l in str.split ('\n')])
+
+        
+        str = '<font size="-2"><pre>%s</pre></font>' % str
+        return str
     
     def calc_distance (self):
         if self.contents[0] == self.contents[1]:
@@ -461,7 +468,7 @@ class TextFileCompareLink (FileCompareLink):
         self.diff_lines =  [l for l in diff]
         self.diff_lines = self.diff_lines[2:]
         
-        return float (len ([l for l in self.diff_lines if l[0] in '-+']))
+        return math.sqrt (float (len ([l for l in self.diff_lines if l[0] in '-+'])))
         
     def get_cell (self, oldnew):
         str = ''
@@ -510,7 +517,7 @@ class ProfileFileLink (FileCompareLink):
                   }
         
         for k in ('time', 'cells'):
-            dist += math.exp (self.get_ratio (k) * factor[k]) - 1
+            dist += math.tan (self.get_ratio (k) /(0.5* math.pi)) * factor[k]  - 1
 
         dist = min (dist, 100)
         return dist