From bf3ba196c4da08c45d385a14ba78bca47b6bbf36 Mon Sep 17 00:00:00 2001 From: Richard Tucker Date: Tue, 10 Nov 1998 12:34:36 +0000 Subject: [PATCH] Allow multi-line fields in test header (use \ for continuation) Copied from Perforce Change: 20347 ServerID: perforce.ravenbrook.com --- mps/qa/test/script/headread | 13 +++++++++---- 1 file changed, 9 insertions(+), 4 deletions(-) diff --git a/mps/qa/test/script/headread b/mps/qa/test/script/headread index ac44659ca30..ad7391da2df 100644 --- a/mps/qa/test/script/headread +++ b/mps/qa/test/script/headread @@ -1,5 +1,5 @@ #!/usr/local/bin/perl -# $HopeName: MMQA_harness!script:headread(trunk.14) $ +# $HopeName: MMQA_harness!script:headread(trunk.15) $ # # subroutines to assist in # 1. reading test headers @@ -49,7 +49,12 @@ sub readheader { while (! /END_HEADER/) { ($_ = || die "Couldn't find end of test header in $infile.\n"); chop; - $line = $line."; ".$_; + if ($line =~ /\\$/) { + chop($line); + $line = $line.$_; + } else { + $line = $line."; ".$_; + } } $line =~ s/END_HEADER.*//; @@ -88,7 +93,7 @@ sub readheader { $testid = "$infile (writeable)"; } if ($testid =~ /^\$HopeName:/) { - $testid =~ s/^\$HopeName: MMQA_harness!script:headread(trunk.14) $/$1/; + $testid =~ s/^\$HopeName: MMQA_harness!script:headread(trunk.15) $/$1/; } # # Compatibility with old tests @@ -114,7 +119,7 @@ sub readvals { %keyvalues = (); %keyrelations = (); - s/([^\/]);/$1;;/g; + s/([^\\]);/$1;;/g; foreach (split(/\s*;;\s*/)) { s/\\(\\|;)/$1/g;