diff options
author | Bruno Haible <bruno@clisp.org> | 2020-05-30 16:22:25 +0200 |
---|---|---|
committer | Bruno Haible <bruno@clisp.org> | 2020-05-30 16:22:25 +0200 |
commit | 9e7d098310117f0b17e7868124652a392b0a9854 (patch) | |
tree | 2e607912d66a139bdcc0ba8b3be8b680200a461e /tests | |
parent | 7168ecc9cc88793fedca103ae8fc7be56349ca41 (diff) | |
download | gnulib-9e7d098310117f0b17e7868124652a392b0a9854.tar.gz |
sys_random: Add C++ tests.
* tests/test-sys_random-c++.cc: New file.
* modules/sys_random-c++-tests: New file.
* modules/sys_random-tests (Depends-on): Depend on it.
Diffstat (limited to 'tests')
-rw-r--r-- | tests/test-sys_random-c++.cc | 35 |
1 files changed, 35 insertions, 0 deletions
diff --git a/tests/test-sys_random-c++.cc b/tests/test-sys_random-c++.cc new file mode 100644 index 0000000000..7477b3a9f4 --- /dev/null +++ b/tests/test-sys_random-c++.cc @@ -0,0 +1,35 @@ +/* Test of <sys/random.h> substitute in C++ mode. + Copyright (C) 2020 Free Software Foundation, Inc. + + This program is free software: you can redistribute it and/or modify + it under the terms of the GNU General Public License as published by + the Free Software Foundation; either version 3 of the License, or + (at your option) any later version. + + This program is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + GNU General Public License for more details. + + You should have received a copy of the GNU General Public License + along with this program. If not, see <https://www.gnu.org/licenses/>. */ + +/* Written by Bruno Haible <bruno@clisp.org>, 2020. */ + +#define GNULIB_NAMESPACE gnulib +#include <config.h> + +#include <sys/random.h> + +#include "signature.h" + + +#if GNULIB_TEST_GETRANDOM +SIGNATURE_CHECK (GNULIB_NAMESPACE::getrandom, ssize_t, (void *, size_t, unsigned int)); +#endif + + +int +main () +{ +} |