From: Don Armstrong Date: Sun, 8 Jul 2012 00:42:55 +0000 (-0700) Subject: support attachments in test scripts X-Git-Tag: release/2.6.0~382 X-Git-Url: https://git.donarmstrong.com/?p=debbugs.git;a=commitdiff_plain;h=ed79523a5a64a6f0462f87eb6ce8e69a14f5fcf9 support attachments in test scripts --- diff --git a/t/lib/DebbugsTest.pm b/t/lib/DebbugsTest.pm index 4e510f6..253f1d7 100644 --- a/t/lib/DebbugsTest.pm +++ b/t/lib/DebbugsTest.pm @@ -145,6 +145,9 @@ sub send_message{ }, body => {type => SCALAR, }, + attachments => {type => ARRAYREF, + default => [], + }, run_processall =>{type => BOOLEAN, default => 1, }, @@ -158,7 +161,9 @@ sub send_message{ my $pid = open3($wfd,$rfd,$rfd,'scripts/receive') or die "Unable to start receive: $!"; print {$wfd} create_mime_message($param{headers}, - $param{body}) or die "Unable to to print to receive"; + $param{body}, + $param{attachments}) or + die "Unable to to print to receive"; close($wfd) or die "Unable to close receive"; my $err = $? >> 8; my $childpid = waitpid($pid,0);