[gcc r14-8629] libstdc++: Fix check in testsuite/std/time/clock/gps/io.cc

Jonathan Wakely redi@gcc.gnu.org
Tue Jan 30 14:54:51 GMT 2024


https://gcc.gnu.org/g:5525dd754b84cef3afe43dc7fdf27664873f137b

commit r14-8629-g5525dd754b84cef3afe43dc7fdf27664873f137b
Author: Jonathan Wakely <jwakely@redhat.com>
Date:   Mon Jan 22 10:48:55 2024 +0000

    libstdc++: Fix check in testsuite/std/time/clock/gps/io.cc
    
    The test_format() function contained an incorrect assertion but wasn't
    actually being called from main.
    
    libstdc++-v3/ChangeLog:
    
            * testsuite/std/time/clock/gps/io.cc: Fix expected result in
            assertion and call test_format() from main.

Diff:
---
 libstdc++-v3/testsuite/std/time/clock/gps/io.cc | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/libstdc++-v3/testsuite/std/time/clock/gps/io.cc b/libstdc++-v3/testsuite/std/time/clock/gps/io.cc
index 5d15713c69dd..d5405f61520a 100644
--- a/libstdc++-v3/testsuite/std/time/clock/gps/io.cc
+++ b/libstdc++-v3/testsuite/std/time/clock/gps/io.cc
@@ -42,7 +42,7 @@ test_format()
 
   // PR libstdc++/113500
   s = std::format("{}", gt + 150ms + 10.5s);
-  VERIFY( s == "2000-01-01 00:00:35.650" );
+  VERIFY( s == "2000-01-01 00:00:23.650" );
 }
 
 void
@@ -65,5 +65,6 @@ test_parse()
 int main()
 {
   test_ostream();
+  test_format();
   test_parse();
 }


More information about the Libstdc++-cvs mailing list