Source-Changes-HG archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

[src/trunk]: src/tests/usr.bin/c++ Use more C++ sugar in t_cxxruntime (ATF test)



details:   https://anonhg.NetBSD.org/src/rev/12b2e774fee7
branches:  trunk
changeset: 823895:12b2e774fee7
user:      kamil <kamil%NetBSD.org@localhost>
date:      Sun May 14 01:13:44 2017 +0000

description:
Use more C++ sugar in t_cxxruntime (ATF test)

diffstat:

 tests/usr.bin/c++/t_cxxruntime.sh |  10 +++++-----
 1 files changed, 5 insertions(+), 5 deletions(-)

diffs (32 lines):

diff -r 98331401eab1 -r 12b2e774fee7 tests/usr.bin/c++/t_cxxruntime.sh
--- a/tests/usr.bin/c++/t_cxxruntime.sh Sun May 14 01:03:21 2017 +0000
+++ b/tests/usr.bin/c++/t_cxxruntime.sh Sun May 14 01:13:44 2017 +0000
@@ -1,4 +1,4 @@
-#      $NetBSD: t_cxxruntime.sh,v 1.1 2017/05/14 01:03:21 kamil Exp $
+#      $NetBSD: t_cxxruntime.sh,v 1.2 2017/05/14 01:13:44 kamil Exp $
 #
 # Copyright (c) 2017 The NetBSD Foundation, Inc.
 # All rights reserved.
@@ -110,9 +110,9 @@
        fi
 
        cat > test.cpp << EOF
-#include <stdio.h>
-#include <stdlib.h>
-int main(void) {printf("hello world\n");exit(0);}
+#include <cstdlib>
+#include <iostream>
+int main(void) {std::cout << "hello world" << std::endl;exit(0);}
 EOF
        atf_check -s exit:0 -o ignore -e ignore c++ -o hello32 -m32 test.cpp
        atf_check -s exit:0 -o ignore -e ignore c++ -o hello64 test.cpp
@@ -129,8 +129,8 @@
 
        # do another test with static 32bit binaries
        cat > test.cpp << EOF
+#include <cstdlib>
 #include <iostream>
-#include <cstdlib>
 int main(void) {std::cout << "hello static world" << std::endl;exit(0);}
 EOF
        atf_check -s exit:0 -o ignore -e ignore c++ -o hello -m32 \



Home | Main Index | Thread Index | Old Index