summaryrefslogtreecommitdiffstats
path: root/test/local.at
blob: 369978ff9548b70e90def367cdb59686f284a653 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
AT_COPYRIGHT([Copyright (C) 2007,2008 Hans Ulrich Niedermann])
AT_TESTED([autom4te autoconf autoheader autoupdate autoreconf])
# Local initialization of the test environment would happen here


m4_define([AT_CREATE_GIT_AM], [dnl
AT_CHECK([mkdir test.git && cd test.git])
AT_CHECK([cd test.git && git init], [0],
[Initialized empty Git repository in .git/
])
AT_DATA([test.git/configure.ac], [dnl
AC[_]INIT(nbb git/automake test, 1.2.3, invalid@invalid.invalid, nbb-git-am-test)
AC_CONFIG_SRCDIR([foobar.c])
AM[_]INIT_AUTOMAKE([-Wall foreign])
AC_PROG_CC
AC_PROG_INSTALL
AC[_]CONFIG_FILES(@<:@Makefile@:>@)
AC[_]OUTPUT
])dnl
AT_DATA([test.git/Makefile.am], [dnl
bin_PROGRAMS = foobar
foobar_SOURCES = foobar.c
])dnl
AT_DATA([test.git/foobar.c], [dnl
#include <stdio.h>
int main(int argc, char *argv@<:@@:>@) {
    printf("FOOBAR!\n");
    return 0;
}
])dnl
])dnl

m4_define([AT_REMOVE_GIT_AM], [dnl
AT_CHECK([rm -rf test.git])
])dnl