aboutsummaryrefslogtreecommitdiff
path: root/gcc
diff options
context:
space:
mode:
authorJonathan Wakely <jwakely@redhat.com>2024-07-22 14:39:57 +0100
committerThomas Koenig <tkoenig@gcc.gnu.org>2024-07-28 19:05:50 +0200
commit5552c6fc01f5b9402ca48a7ffa548aa9fb1d4387 (patch)
tree310ad00f47ee600b9afb14c5de2716da791c1343 /gcc
parent815d1e048ac50f718e351fba0b2ef11319fab1dd (diff)
downloadgcc-5552c6fc01f5b9402ca48a7ffa548aa9fb1d4387.zip
gcc-5552c6fc01f5b9402ca48a7ffa548aa9fb1d4387.tar.gz
gcc-5552c6fc01f5b9402ca48a7ffa548aa9fb1d4387.tar.bz2
libstdc++: Add file-io-diff to replace @diff@ markup in I/O tests
This adds a new dg-final action to compare two files after a test has run, so that we can verify that fstream operations produce the expected results. With this change, all uses of @diff@ that seem potentially useful have been converted to actually compare the files and FAIL if they differ. The file-io-diff action can take two arguments naming the files to be compared, or for convenience it can take a single string and will compare STR.tst and STR.txt, as that's how it's commonly used. Additionally, all remaining uses of @require@ are converted to dg-additional-files directives, so that the TODO in libstdc++.exp can be resolved. libstdc++-v3/ChangeLog: * testsuite/27_io/basic_filebuf/close/char/1.cc: Remove @require@ and @diff@. Use dg-final file-io-diff action. * testsuite/27_io/basic_istream/extractors_other/char/2.cc: Likewise. * testsuite/27_io/basic_istream/extractors_other/wchar_t/2.cc: Likewise. * testsuite/27_io/basic_istream/get/char/2.cc: Likewise. * testsuite/27_io/basic_istream/get/wchar_t/2.cc: Likewise. * testsuite/27_io/basic_istream/ignore/char/3.cc: Likewise. * testsuite/27_io/basic_istream/ignore/wchar_t/3.cc: Likewise. * testsuite/27_io/basic_istream/peek/char/6414.cc: Likewise. * testsuite/27_io/basic_istream/peek/wchar_t/6414.cc: Likewise. * testsuite/27_io/basic_istream/seekg/char/fstream.cc: Likewise. * testsuite/27_io/basic_istream/seekg/wchar_t/fstream.cc: Likewise. * testsuite/27_io/basic_istream/tellg/char/fstream.cc: Likewise. * testsuite/27_io/basic_istream/tellg/wchar_t/fstream.cc: Likewise. * testsuite/27_io/basic_ofstream/open/char/1.cc: Likewise. * testsuite/27_io/basic_ostream/inserters_other/char/1.cc: Likewise. * testsuite/27_io/basic_ostream/inserters_other/wchar_t/1.cc: Likewise. * testsuite/27_io/ios_base/sync_with_stdio/1.cc: Likewise. * testsuite/27_io/basic_ostream/inserters_other/char/2.cc: Likewise. Check file positions. * testsuite/27_io/basic_ostream/inserters_other/wchar_t/2.cc: Likewise. * testsuite/lib/libstdc++.exp (file-io-diff): New proc.
Diffstat (limited to 'gcc')
0 files changed, 0 insertions, 0 deletions