tests: expose automake bug#14560
[platform/upstream/automake.git] / t / c-demo.sh
old mode 100755 (executable)
new mode 100644 (file)
index ed2a109..df2fc55
@@ -1,5 +1,5 @@
 #! /bin/sh
-# Copyright (C) 2012 Free Software Foundation, Inc.
+# Copyright (C) 2012-2013 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
@@ -19,7 +19,7 @@
 
 required=cc
 am_create_testdir=empty
-. ./defs || Exit 1
+. test-init.sh
 
 cat > configure.ac << 'END'
 AC_INIT([GNU C Demo], [22.3.2], [bug-automake@gnu.org])
@@ -154,8 +154,8 @@ $MAKE test-objs
 
 VERBOSE=x $MAKE check
 if cross_compiling; then
-  test ! -f tests/test-suite.log
-  test ! -f tests/test.log
+  test ! -e tests/test-suite.log
+  test ! -e tests/test.log
 else
   test -f tests/test-suite.log
   grep 'Foo, Bar!' tests/test.log
@@ -169,11 +169,11 @@ if ! cross_compiling && ! grep "[ $tab]depmode=none" Makefile; then
   mv -f t lib/bar.h
   $MAKE
   ./src/zardoz
-  test "`./src/zardoz`" = 'Foo, Zap!'
+  test "$(./src/zardoz)" = 'Foo, Zap!'
 fi
 
 $MAKE clean
-test ! -f lib/foo.h
+test ! -e lib/foo.h
 test -f lib/bar.h
 
 :