X-Git-Url: http://erislabs.net/gitweb/?a=blobdiff_plain;f=tests%2Ftest-canonicalize-lgpl.c;h=6a5c45d7663ef60eef911e9735c56fa60b465eff;hb=aae58b6f7bd0f7c2f38e05eb005b76c164c5c1f7;hp=4f4fca18b4460ff51c9b4d0db9c79635155d8eaa;hpb=89ae4589dd58d12e7cbcf0e92c1d828c1e430f97;p=gnulib.git diff --git a/tests/test-canonicalize-lgpl.c b/tests/test-canonicalize-lgpl.c index 4f4fca18b..6a5c45d76 100644 --- a/tests/test-canonicalize-lgpl.c +++ b/tests/test-canonicalize-lgpl.c @@ -1,5 +1,5 @@ /* Test of execution of program termination handlers. - Copyright (C) 2007-2009 Free Software Foundation, Inc. + Copyright (C) 2007-2010 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 @@ -32,18 +32,8 @@ SIGNATURE_CHECK (canonicalize_file_name, char *, (const char *)); #include #include "same-inode.h" - -#define ASSERT(expr) \ - do \ - { \ - if (!(expr)) \ - { \ - fprintf (stderr, "%s:%d: assertion failed\n", __FILE__, __LINE__); \ - fflush (stderr); \ - abort (); \ - } \ - } \ - while (0) +#include "ignore-value.h" +#include "macros.h" #define BASE "t-can-lgpl.tmp" @@ -56,7 +46,7 @@ null_ptr (void) int main (void) { -#ifdef GNULIB_CANONICALIZE +#if GNULIB_TEST_CANONICALIZE /* No need to test canonicalize-lgpl module if canonicalize is also in use. */ return 0; @@ -66,7 +56,7 @@ main (void) any leftovers from a previous partial run. */ { int fd; - ASSERT (system ("rm -rf " BASE " ise") == 0); + ignore_value (system ("rm -rf " BASE " ise")); ASSERT (mkdir (BASE, 0700) == 0); fd = creat (BASE "/tra", 0600); ASSERT (0 <= fd);