Add exectest.pl OLD-/NEW-FAILURE for deliberate idlc/unoidl diffs
Change-Id: I653522d8ebaac3329f368c102d14041c6b49d41d
This commit is contained in:
@@ -28,52 +28,52 @@ $(call gb_CustomTarget_get_target,idlc/parser_test) : \
|
|||||||
$(call gb_Helper_abbreviate_dirs,( \
|
$(call gb_Helper_abbreviate_dirs,( \
|
||||||
$(PERL) $(SRCDIR)/solenv/bin/exectest.pl \
|
$(PERL) $(SRCDIR)/solenv/bin/exectest.pl \
|
||||||
$(SRCDIR)/idlc/test/parser/attribute.tests \
|
$(SRCDIR)/idlc/test/parser/attribute.tests \
|
||||||
$(call gb_CustomTarget_get_workdir,idlc/parser_test)/in.idl \
|
$(call gb_CustomTarget_get_workdir,idlc/parser_test)/in.idl 0 \
|
||||||
$(call gb_Executable_get_command,idlc) \
|
$(call gb_Executable_get_command,idlc) \
|
||||||
-O $(call gb_CustomTarget_get_workdir,idlc/parser_test) {} && \
|
-O $(call gb_CustomTarget_get_workdir,idlc/parser_test) {} && \
|
||||||
$(PERL) $(SRCDIR)/solenv/bin/exectest.pl \
|
$(PERL) $(SRCDIR)/solenv/bin/exectest.pl \
|
||||||
$(SRCDIR)/idlc/test/parser/constant.tests \
|
$(SRCDIR)/idlc/test/parser/constant.tests \
|
||||||
$(call gb_CustomTarget_get_workdir,idlc/parser_test)/in.idl \
|
$(call gb_CustomTarget_get_workdir,idlc/parser_test)/in.idl 0 \
|
||||||
$(call gb_Executable_get_command,idlc) \
|
$(call gb_Executable_get_command,idlc) \
|
||||||
-O $(call gb_CustomTarget_get_workdir,idlc/parser_test) {} && \
|
-O $(call gb_CustomTarget_get_workdir,idlc/parser_test) {} && \
|
||||||
$(PERL) $(SRCDIR)/solenv/bin/exectest.pl \
|
$(PERL) $(SRCDIR)/solenv/bin/exectest.pl \
|
||||||
$(SRCDIR)/idlc/test/parser/constructor.tests \
|
$(SRCDIR)/idlc/test/parser/constructor.tests \
|
||||||
$(call gb_CustomTarget_get_workdir,idlc/parser_test)/in.idl \
|
$(call gb_CustomTarget_get_workdir,idlc/parser_test)/in.idl 0 \
|
||||||
$(call gb_Executable_get_command,idlc) \
|
$(call gb_Executable_get_command,idlc) \
|
||||||
-O $(call gb_CustomTarget_get_workdir,idlc/parser_test) {} && \
|
-O $(call gb_CustomTarget_get_workdir,idlc/parser_test) {} && \
|
||||||
$(PERL) $(SRCDIR)/solenv/bin/exectest.pl \
|
$(PERL) $(SRCDIR)/solenv/bin/exectest.pl \
|
||||||
$(SRCDIR)/idlc/test/parser/interfaceinheritance.tests \
|
$(SRCDIR)/idlc/test/parser/interfaceinheritance.tests \
|
||||||
$(call gb_CustomTarget_get_workdir,idlc/parser_test)/in.idl \
|
$(call gb_CustomTarget_get_workdir,idlc/parser_test)/in.idl 0 \
|
||||||
$(call gb_Executable_get_command,idlc) \
|
$(call gb_Executable_get_command,idlc) \
|
||||||
-O $(call gb_CustomTarget_get_workdir,idlc/parser_test) {} && \
|
-O $(call gb_CustomTarget_get_workdir,idlc/parser_test) {} && \
|
||||||
$(PERL) $(SRCDIR)/solenv/bin/exectest.pl \
|
$(PERL) $(SRCDIR)/solenv/bin/exectest.pl \
|
||||||
$(SRCDIR)/idlc/test/parser/methodoverload.tests \
|
$(SRCDIR)/idlc/test/parser/methodoverload.tests \
|
||||||
$(call gb_CustomTarget_get_workdir,idlc/parser_test)/in.idl \
|
$(call gb_CustomTarget_get_workdir,idlc/parser_test)/in.idl 0 \
|
||||||
$(call gb_Executable_get_command,idlc) \
|
$(call gb_Executable_get_command,idlc) \
|
||||||
-O $(call gb_CustomTarget_get_workdir,idlc/parser_test) {} && \
|
-O $(call gb_CustomTarget_get_workdir,idlc/parser_test) {} && \
|
||||||
$(PERL) $(SRCDIR)/solenv/bin/exectest.pl \
|
$(PERL) $(SRCDIR)/solenv/bin/exectest.pl \
|
||||||
$(SRCDIR)/idlc/test/parser/oldstyle.tests \
|
$(SRCDIR)/idlc/test/parser/oldstyle.tests \
|
||||||
$(call gb_CustomTarget_get_workdir,idlc/parser_test)/in.idl \
|
$(call gb_CustomTarget_get_workdir,idlc/parser_test)/in.idl 0 \
|
||||||
$(call gb_Executable_get_command,idlc) \
|
$(call gb_Executable_get_command,idlc) \
|
||||||
-O $(call gb_CustomTarget_get_workdir,idlc/parser_test) {} && \
|
-O $(call gb_CustomTarget_get_workdir,idlc/parser_test) {} && \
|
||||||
$(PERL) $(SRCDIR)/solenv/bin/exectest.pl \
|
$(PERL) $(SRCDIR)/solenv/bin/exectest.pl \
|
||||||
$(SRCDIR)/idlc/test/parser/polystruct.tests \
|
$(SRCDIR)/idlc/test/parser/polystruct.tests \
|
||||||
$(call gb_CustomTarget_get_workdir,idlc/parser_test)/in.idl \
|
$(call gb_CustomTarget_get_workdir,idlc/parser_test)/in.idl 0 \
|
||||||
$(call gb_Executable_get_command,idlc) \
|
$(call gb_Executable_get_command,idlc) \
|
||||||
-O $(call gb_CustomTarget_get_workdir,idlc/parser_test) {} && \
|
-O $(call gb_CustomTarget_get_workdir,idlc/parser_test) {} && \
|
||||||
$(PERL) $(SRCDIR)/solenv/bin/exectest.pl \
|
$(PERL) $(SRCDIR)/solenv/bin/exectest.pl \
|
||||||
$(SRCDIR)/idlc/test/parser/published.tests \
|
$(SRCDIR)/idlc/test/parser/published.tests \
|
||||||
$(call gb_CustomTarget_get_workdir,idlc/parser_test)/in.idl \
|
$(call gb_CustomTarget_get_workdir,idlc/parser_test)/in.idl 0 \
|
||||||
$(call gb_Executable_get_command,idlc) \
|
$(call gb_Executable_get_command,idlc) \
|
||||||
-O $(call gb_CustomTarget_get_workdir,idlc/parser_test) {} && \
|
-O $(call gb_CustomTarget_get_workdir,idlc/parser_test) {} && \
|
||||||
$(PERL) $(SRCDIR)/solenv/bin/exectest.pl \
|
$(PERL) $(SRCDIR)/solenv/bin/exectest.pl \
|
||||||
$(SRCDIR)/idlc/test/parser/struct.tests \
|
$(SRCDIR)/idlc/test/parser/struct.tests \
|
||||||
$(call gb_CustomTarget_get_workdir,idlc/parser_test)/in.idl \
|
$(call gb_CustomTarget_get_workdir,idlc/parser_test)/in.idl 0 \
|
||||||
$(call gb_Executable_get_command,idlc) \
|
$(call gb_Executable_get_command,idlc) \
|
||||||
-O $(call gb_CustomTarget_get_workdir,idlc/parser_test) {} && \
|
-O $(call gb_CustomTarget_get_workdir,idlc/parser_test) {} && \
|
||||||
$(PERL) $(SRCDIR)/solenv/bin/exectest.pl \
|
$(PERL) $(SRCDIR)/solenv/bin/exectest.pl \
|
||||||
$(SRCDIR)/idlc/test/parser/typedef.tests \
|
$(SRCDIR)/idlc/test/parser/typedef.tests \
|
||||||
$(call gb_CustomTarget_get_workdir,idlc/parser_test)/in.idl \
|
$(call gb_CustomTarget_get_workdir,idlc/parser_test)/in.idl 0 \
|
||||||
$(call gb_Executable_get_command,idlc) \
|
$(call gb_Executable_get_command,idlc) \
|
||||||
-O $(call gb_CustomTarget_get_workdir,idlc/parser_test) {}) \
|
-O $(call gb_CustomTarget_get_workdir,idlc/parser_test) {}) \
|
||||||
> $@.log 2>&1 || (cat $@.log && false))
|
> $@.log 2>&1 || (cat $@.log && false))
|
||||||
|
@@ -23,18 +23,21 @@ sub encode($)
|
|||||||
return $arg
|
return $arg
|
||||||
}
|
}
|
||||||
|
|
||||||
$#ARGV >= 2
|
$#ARGV >= 3
|
||||||
or die "Usage: $0 <input file> <temp file> <command> <arguments...>";
|
or die "Usage: $0 <input file> <temp file> <new?> <command> <arguments...>";
|
||||||
open INPUT, '<', $ARGV[0] or die "cannot open $ARGV[0]: $!";
|
open INPUT, '<', $ARGV[0] or die "cannot open $ARGV[0]: $!";
|
||||||
shift @ARGV;
|
shift @ARGV;
|
||||||
$temp = $ARGV[0];
|
$temp = $ARGV[0];
|
||||||
shift @ARGV;
|
shift @ARGV;
|
||||||
|
$new = $ARGV[0];
|
||||||
|
shift @ARGV;
|
||||||
$failed = 0;
|
$failed = 0;
|
||||||
$open = 0;
|
$open = 0;
|
||||||
while (1) {
|
while (1) {
|
||||||
$eof = eof INPUT;
|
$eof = eof INPUT;
|
||||||
$in = <INPUT> unless $eof;
|
$in = <INPUT> unless $eof;
|
||||||
if ($eof || $in =~ /^EXPECT (SUCCESS|FAILURE) "([^"]*)"?:\n$/)
|
if ($eof
|
||||||
|
|| $in =~ /^EXPECT (SUCCESS|FAILURE|NEW-FAILURE|OLD-FAILURE) "([^"]*)"?:\n$/)
|
||||||
{
|
{
|
||||||
if ($open)
|
if ($open)
|
||||||
{
|
{
|
||||||
@@ -86,6 +89,8 @@ while (1) {
|
|||||||
}
|
}
|
||||||
last if $eof;
|
last if $eof;
|
||||||
$expect = $1;
|
$expect = $1;
|
||||||
|
$expect = ($new ? 'FAILURE' : 'SUCCESS') if $expect eq 'NEW-FAILURE';
|
||||||
|
$expect = ($new ? 'SUCCESS' : 'FAILURE') if $expect eq 'OLD-FAILURE';
|
||||||
$title = $2;
|
$title = $2;
|
||||||
open OUTPUT, '>', $temp or die "cannot open $temp: $!";
|
open OUTPUT, '>', $temp or die "cannot open $temp: $!";
|
||||||
$open = 1;
|
$open = 1;
|
||||||
|
Reference in New Issue
Block a user