From acfd42286515cc0d03df9cf947e7488891dfc2e3 Mon Sep 17 00:00:00 2001 From: Ralf Wildenhues Date: Sat, 14 Nov 2009 21:56:49 +0100 Subject: [PATCH] Coverage for syntax errors with conditionals in included fragments. * tests/condinc2.test: Amend test. Signed-off-by: Ralf Wildenhues --- ChangeLog | 3 +++ tests/condinc2.test | 23 ++++++++++++++++++++++- 2 files changed, 25 insertions(+), 1 deletion(-) diff --git a/ChangeLog b/ChangeLog index 8f0a2dd40..adab68a84 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,5 +1,8 @@ 2009-11-14 Ralf Wildenhues + Coverage for syntax errors with conditionals in included fragments. + * tests/condinc2.test: Amend test. + Coverage: diagnose variables with forbidden dist_ prefix. * tests/candist.test: New test. * tests/Makefile.am: Update. diff --git a/tests/condinc2.test b/tests/condinc2.test index 088fb5592..69eff5950 100755 --- a/tests/condinc2.test +++ b/tests/condinc2.test @@ -1,5 +1,6 @@ #! /bin/sh -# Copyright (C) 1999, 2001, 2002, 2003 Free Software Foundation, Inc. +# Copyright (C) 1999, 2001, 2002, 2003, 2009 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 @@ -39,3 +40,23 @@ END $ACLOCAL AUTOMAKE_fails grep 'adjunct:3: too many conditionals closed' stderr + +cat > adjunct << 'END' +if TOBE +target: dependency + rule +END + +AUTOMAKE_fails +grep 'unterminated conditionals' stderr + +cat > adjunct << 'END' +if TOBE +target: dependency + rule +endif +END + +$AUTOMAKE + +Exit 0 -- 2.47.2