]> git.ipfire.org Git - thirdparty/gcc.git/commitdiff
testsuite: The expect framework might introduce CR in output
authorTorbjörn SVENSSON <torbjorn.svensson@foss.st.com>
Sat, 11 Jan 2025 18:16:57 +0000 (19:16 +0100)
committerTorbjörn SVENSSON <torbjorn.svensson@foss.st.com>
Sun, 12 Jan 2025 07:34:50 +0000 (08:34 +0100)
When running tests using the "sim" config, the command is launched in
non-readonly mode and the text retrieved from the expect command will
then replace all LF with CRLF. (The problem can be found in sim_load
where it calls remote_spawn without an input file).

libstdc++-v3/ChangeLog:

* testsuite/27_io/print/1.cc: Allow both LF and CRLF in test.
* testsuite/27_io/print/3.cc: Likewise.

Signed-off-by: Torbjörn SVENSSON <torbjorn.svensson@foss.st.com>
libstdc++-v3/testsuite/27_io/print/1.cc
libstdc++-v3/testsuite/27_io/print/3.cc

index f6585d9880ae9cb234e60db6773dde357adcef7a..2a74e5002f449bcc09fbc203bd3ba98386bfb50e 100644 (file)
@@ -18,7 +18,7 @@ void
 test_println_default()
 {
   std::println("I walk the line");
-  // { dg-output "I walk the line\n" }
+  // { dg-output "I walk the line\r?\n" }
 }
 
 void
index ffcf7337ce5d547089d8addcfbe156ad8684b2f4..90c4cfb0d48d6278499739babe74873043b3653d 100644 (file)
@@ -13,7 +13,7 @@ test_println_blank()
   std::print("1");
   std::println();
   std::println("2");
-  // { dg-output "1\n2" }
+  // { dg-output "1\r?\n2" }
 }
 
 void