ENH: add test for source_group

Alex
This commit is contained in:
Alexander Neundorf 2007-08-24 10:39:51 -04:00
parent d634c4e743
commit e7a1b85f76
6 changed files with 37 additions and 0 deletions

View File

@ -0,0 +1,9 @@
#source_group(Base FILES main.c)
#source_group(Base\\Sub1 FILES sub1/foo.c)
#source_group(Base\\Sub1\\Sub2 FILES sub1/foobar.c)
#source_group("" FILES foo.c)
#source_group("\\" FILES bar.c)
add_executable(SourceGroups main.c bar.c foo.c sub1/foo.c sub1/foobar.c)

4
Tests/SourceGroups/bar.c Normal file
View File

@ -0,0 +1,4 @@
int barbar(void)
{
return 2;
}

4
Tests/SourceGroups/foo.c Normal file
View File

@ -0,0 +1,4 @@
int bar(void)
{
return 42;
}

12
Tests/SourceGroups/main.c Normal file
View File

@ -0,0 +1,12 @@
#include <stdio.h>
extern int foo(void);
extern int bar(void);
extern int foobar(void);
extern int barbar(void);
int main()
{
printf("foo: %d bar: %d foobar: %d barbar: %d\n", foo(), bar(), foobar(), barbar());
return 0;
}

View File

@ -0,0 +1,4 @@
int foo(void)
{
return 17;
}

View File

@ -0,0 +1,4 @@
int foobar(void)
{
return 1477;
}