Add a test for escaped newline handling.

This commit is contained in:
harti 2005-06-01 11:26:47 +00:00
parent 10c793046d
commit 54f37e8648
8 changed files with 45 additions and 0 deletions

View File

@ -0,0 +1,25 @@
# $FreeBSD$
#
# Test handling of escaped newlines.
#
.ifmake test1
# This should succeed
\
\
\
test1:
@echo ok
.elifmake test2
# This should fail because the comment continues on the next lines leading
# to an unassociated shell command.
\
#\
\
test2:
@echo ok
.endif

View File

@ -0,0 +1 @@
0

View File

@ -0,0 +1 @@
1

View File

@ -0,0 +1,2 @@
"Makefile", line 23: Unassociated shell command "@echo ok"
make: fatal errors encountered -- cannot continue

View File

@ -0,0 +1 @@
ok

View File

@ -0,0 +1,15 @@
#!/bin/sh
# $FreeBSD$
cd `dirname $0`
. ../../common.sh
# Description
DESC="Test escaped new-lines handling."
# Run
TEST_N=2
TEST_2_TODO="bug in parser"
eval_cmd $*