Changeset 27969 for other-projects/nightly-tasks/diffcol/trunk
- Timestamp:
- 2013-08-05T15:28:32+12:00 (11 years ago)
- Location:
- other-projects/nightly-tasks/diffcol/trunk/diffcol
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
other-projects/nightly-tasks/diffcol/trunk/diffcol/diffcol.pl
r27767 r27969 576 576 # Files to be skipped because they get generated on one OS but not the other 577 577 # On windows, files of the form col.invf.state.\d\d\d\d get generated (e.g. Small-HTML.invf.state.1228) that aren't there on linux 578 my $skipfiles_re = qr/ \.invf\.state\.\d+$/; # Create a regex of all files to be skipped, see http://perldoc.perl.org/perlop.html578 my $skipfiles_re = qr/(\.invf\.state\.\d+$)|~$/; # Create a regex of all files to be skipped, see http://perldoc.perl.org/perlop.html 579 579 @aryInModel = grep { $_ !~ m/$skipfiles_re/ } @aryInModel; # http://stackoverflow.com/questions/174292/what-is-the-best-way-to-delete-a-value-from-an-array-in-perl 580 580 @aryInTest = grep { $_ !~ m/$skipfiles_re/ } @aryInTest; … … 592 592 my $strNewTest = &FileUtils::filenameConcatenate($strTest,$strEachFile); 593 593 # now additionally ignoring the earliestDatestamp file and the index/idx/*.idh binary file when diffing file 594 if(!($strEachFile eq "log" || $strEachFile eq "earliestDatestamp" || $strEachFile =~ m/\.cfg$/g || $strEachFile =~ m/ \.((g|j|l|b)db|idh|i.*|wa|td|tsd|ti|t|tl|w|jpe?g|gif|png|wmf)$/g)) # wmf = windows meta file594 if(!($strEachFile eq "log" || $strEachFile eq "earliestDatestamp" || $strEachFile =~ m/\.cfg$/g || $strEachFile =~ m/collect\.bak$/g || $strEachFile =~ m/\.((g|j|l|b)db|idh|i.*|wa|td|tsd|ti|t|tl|w|jpe?g|gif|png|wmf)$/g)) # wmf = windows meta file # || $strEachFile =~ m/\~$/g to get rid of ~ files 595 595 { 596 596 push(@Errors,TestEach($strNewModel,$strNewTest,$intLevel,$strColName)); … … 612 612 my $strNewModel = &FileUtils::filenameConcatenate($strModel,$strEachFile); 613 613 my $strNewTest = &FileUtils::filenameConcatenate($strTest,$strEachFile); 614 if(!($strEachFile eq "log" || $strEachFile eq "earliestDatestamp" || $strEachFile =~ m/\.cfg$/g || $strEachFile =~ m/ \.((g|j|l|b)db|idh|i.*|wa|td|tsd|ti|t|tl|w|jpe?g|gif|png|wmf)$/g))614 if(!($strEachFile eq "log" || $strEachFile eq "earliestDatestamp" || $strEachFile =~ m/\.cfg$/g || $strEachFile =~ m/collect\.bak$/g || $strEachFile =~ m/\.((g|j|l|b)db|idh|i.*|wa|td|tsd|ti|t|tl|w|jpe?g|gif|png|wmf)$/g)) # || $strEachFile =~ m/\~$/g to get rid of ~ files 615 615 { 616 616 push(@Errors,TestEach($strNewModel,$strNewTest,$intLevel,$strColName)); … … 626 626 else 627 627 { 628 my $ignore_line_re = "<Metadata name=\"(lastmodified|lastmodifieddate|oailastmodified|oailastmodifieddate|ex.File.FileModifyDate|ex.File.FilePermissions|ImageSize)\">.*</Metadata>\\s*\\n*"; 628 my $ignore_line_re = "<Metadata name=\"(lastmodified|lastmodifieddate|oailastmodified|oailastmodifieddate|ex.File.FileModifyDate|ex.File.FilePermissions|ImageSize)\">.*</Metadata>\\s*\\n*"; 629 629 630 630 my $strResult; … … 859 859 860 860 if ( length( $strOutput ) > 1000 ) { 861 $strOutput = substr( $strOutput, 0, 978) . "... (output truncated)"; 861 $strOutput = substr( $strOutput, 0, 978); 862 863 # make sure there are no stray ampersands/partial ampersands that need to be completed as < or > 864 if($strOutput =~ m/&(.{1,2})?$/) { # < => < or &g => > 865 if(defined $1 && $1) { 866 my $rest = $1; 867 if($rest eq "g" || $rest eq "l") { 868 $strOutput .= "t;"; # close the known tag 869 } 870 elsif($1 eq "gt" || $1 eq "lt") { 871 $strOutput .= ";"; 872 } 873 } else { # & on its own 874 #$strOutput = substr( $strOutput, 0, 977); # lop off the & 875 $strOutput .= "gt;"; # 50% chance the closing tag is what was missing (else can make this &) 876 # but even so, when the xslt is applied to report it doesn't break as long as & is not left dangling 877 } 878 } 879 $strOutput .= "... (output truncated)"; 862 880 } 863 881 -
other-projects/nightly-tasks/diffcol/trunk/diffcol/gdbdiff.pm
r27767 r27969 66 66 # The total_numbytes field can vary depending on how many backslashes exist in the urls in the main body text, as each 67 67 # of these windows slashes get escaped with another backslash, and the resulting string is used as key into rel link db 68 my $ignore_line_re = "\n<( lastmodified|lastmodifieddate|oailastmodified|oailastmodifieddate|ex.File.FileModifyDate|ex.File.FilePermissions|total_numbytes)>([^\n])*";68 my $ignore_line_re = "\n<(FileSize|lastmodified|lastmodifieddate|oailastmodified|oailastmodifieddate|ex.File.FileModifyDate|ex.File.FilePermissions|total_numbytes)>([^\n])*"; 69 69 $model_text =~ s/$ignore_line_re//g; 70 70 $test_text =~ s/$ignore_line_re//g;
Note:
See TracChangeset
for help on using the changeset viewer.