1 /* Legacy test skeleton.
2 Copyright (C) 1998-2017 Free Software Foundation, Inc.
3 This file is part of the GNU C Library.
4 Contributed by Ulrich Drepper <drepper@cygnus.com>, 1998.
6 The GNU C Library is free software; you can redistribute it and/or
7 modify it under the terms of the GNU Lesser General Public
8 License as published by the Free Software Foundation; either
9 version 2.1 of the License, or (at your option) any later version.
11 The GNU C Library is distributed in the hope that it will be useful,
12 but WITHOUT ANY WARRANTY; without even the implied warranty of
13 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
14 Lesser General Public License for more details.
16 You should have received a copy of the GNU Lesser General Public
17 License along with the GNU C Library; if not, see
18 <http://www.gnu.org/licenses/>. */
20 /* This test skeleton is to support running existing tests. New tests
21 should use <support/test-driver.c> instead; see the documentation
22 in that file for instructions, and <support/README-testing.c> for a
25 /* This list of headers is needed so that tests which include
26 "../test-skeleton.c" at the beginning still compile. */
39 #include <sys/resource.h>
41 #include <sys/param.h>
45 #include <support/support.h>
46 #include <support/check.h>
47 #include <support/xsignal.h>
48 #include <support/temp_file.h>
50 /* TEST_FUNCTION is no longer used. */
52 legacy_test_function (int argc
__attribute__ ((unused
)),
53 char **argv
__attribute__ ((unused
)))
59 return do_test (argc
, argv
);
62 #define TEST_FUNCTION_ARGV legacy_test_function
64 /* PREPARE is a function name in the new skeleton. */
67 legacy_prepare_function (int argc
__attribute__ ((unused
)),
68 char **argv
__attribute__ ((unused
)))
73 # define PREPARE legacy_prepare_function
76 /* CLEANUP_HANDLER is a function name in the new skeleton. */
77 #ifdef CLEANUP_HANDLER
79 legacy_cleanup_handler_function (void)
83 # undef CLEANUP_HANDLER
84 # define CLEANUP_HANDLER legacy_cleanup_handler_function
87 /* CMDLINE_PROCESS is a function name in the new skeleton. */
88 #ifdef CMDLINE_PROCESS
90 legacy_cmdline_process_function (int c
)
97 # undef CMDLINE_PROCESS
98 # define CMDLINE_PROCESS legacy_cmdline_process_function
101 /* Include the new test-skeleton. */
102 #include <support/test-driver.c>
104 /* The following functionality is only available if <pthread.h> was
105 included before this file. */
107 # include <support/xthread.h>
108 #endif /* _PTHREAD_H */