diff options
author | Karel Klic <kklic@redhat.com> | 2010-10-14 16:36:12 +0200 |
---|---|---|
committer | Karel Klic <kklic@redhat.com> | 2010-10-14 16:36:12 +0200 |
commit | 43c74514d0faa39d343a26f39f31ec7689334b7b (patch) | |
tree | 700b3a6a06e3dc02ea94e558cdf46f25144915de /tests/local.at | |
parent | 704a86ddf32df845f7eca34bcb727e398dce8fa2 (diff) | |
download | abrt-43c74514d0faa39d343a26f39f31ec7689334b7b.tar.gz abrt-43c74514d0faa39d343a26f39f31ec7689334b7b.tar.xz abrt-43c74514d0faa39d343a26f39f31ec7689334b7b.zip |
btparser integration: merge it into ABRT's directory hierarchy
Diffstat (limited to 'tests/local.at')
-rw-r--r-- | tests/local.at | 27 |
1 files changed, 27 insertions, 0 deletions
diff --git a/tests/local.at b/tests/local.at new file mode 100644 index 00000000..758906d4 --- /dev/null +++ b/tests/local.at @@ -0,0 +1,27 @@ +# Source: bison local.at + +# ---------------------------------------- +# AT_COMPILE(OUTPUT, [SOURCES = OUTPUT.c]) +# ---------------------------------------- +# Compile SOURCES into OUTPUT. If OUTPUT does not contain '.', +# assume that we are linking too; this is a hack. +m4_define([AT_COMPILE], +[AT_CHECK([$LIBTOOL --mode=link $CC $CFLAGS m4_bmatch([$1], [[.]], [], [$LDFLAGS ])-o $1 m4_default([$2], [$1.c])[]m4_bmatch([$1], [[.]], [], [ $LIBS])], + 0, [ignore], [ignore])]) + +# ------------------------ +# AT_TESTFUN(NAME, SOURCE) +# ------------------------ + +# Create a test named NAME by compiling and running C file with +# contents SOURCE. The stdout and stderr output of the C program is +# ignored by Autotest. + +m4_define([AT_TESTFUN], +[AT_SETUP([$1]) +AT_DATA([$1.c], [$2]) +AT_COMPILE([$1]) +AT_CHECK([./$1], 0, [ignore], [ignore]) +AT_CLEANUP]) + +AT_INIT |