This is the mail archive of the libstdc++@gcc.gnu.org mailing list for the libstdc++ project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]

Re: how are xfails supposed to work?


Benjamin Kosnik <bkoz@redhat.com> writes:

| ..the g++ testsuite way is not working (embedding XFAIL on the line to 
| fail). The libjava method (make a filename.xfail) seems a bit wasteful. 
| 
| thoughts? Is this something that is working but not checked in?

The dg.exp framework is (unfortunately) documented only in dg.exp.
Here is an extract:

# dg-do do-what-keyword [{ target/xfail selector }]
#       `do-what-keyword' is tool specific and is passed unchanged to
#       ${tool}-dg-test.  An example is gcc where `keyword' can be any
#       of:
#       preprocess|compile|assemble|link|run
#       and will do one of: produce a .i, produce a .s, produce a .o,
#       produce an a.out, or produce an a.out and run it (the default
#       is
#       compile).
#
# dg-error regexp comment [{ target/xfail selector } [{.|0|linenum}]]
#       indicate an error message <regexp> is expected on this line
#       (the test fails if it doesn't occur)
#       Linenum=0 for general tool messages (eg: -V arg missing).
#       "." means the current line.
#
# dg-warning regexp comment [{ target/xfail selector }
#       [{.|0|linenum}]]
#       indicate a warning message <regexp> is expected on this line
#       (the test fails if it doesn't occur)
#
# dg-bogus regexp comment [{ target/xfail selector } [{.|0|linenum}]]
#       indicate a bogus error message <regexp> use to occur here
#       (the test fails if it does occur)
#
# dg-build regexp comment [{ target/xfail selector }]
#       indicate the build use to fail for some reason
#       (errors covered here include bad assembler generated, tool
#       crashes,
#       and link failures)
#       (the test fails if it does occur)
#
# dg-excess-errors comment [{ target/xfail selector }]
#       indicate excess errors are expected (any line)
#       (this should only be used sparingly and temporarily)
#


As said in another message, I'll post a full documentation on how to
write test for V3 -- I'm sorry for the delay but I'm trying to do th
best in the relatively short time I have.

-- Gaby


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]