Browse Source

[tests] move src/test_*.c to src/t/

personal/stbuehler/fix-fdevent
Glenn Strauss 4 years ago
parent
commit
6ccccaaa38
  1. 1
      .gitignore
  2. 2
      configure.ac
  3. 8
      src/CMakeLists.txt
  4. 26
      src/Makefile.am
  5. 8
      src/meson.build
  6. 0
      src/t/test_base64.c
  7. 0
      src/t/test_buffer.c
  8. 0
      src/t/test_configfile.c
  9. 0
      src/t/test_request.c
  10. 1
      tests/CMakeLists.txt

1
.gitignore

@ -3,6 +3,7 @@
*.exe
*~
.deps/
.dirstamp
.libs/
.sconf_temp
.sconsign.dblite

2
configure.ac

@ -21,7 +21,7 @@ AC_CONFIG_MACRO_DIR([m4])
AC_CANONICAL_HOST
AM_INIT_AUTOMAKE([1.13 -Wall -Wno-portability -Wno-override foreign dist-xz tar-ustar serial-tests silent-rules])
AM_INIT_AUTOMAKE([1.13 -Wall -Wno-portability -Wno-override foreign dist-xz tar-ustar serial-tests silent-rules subdir-objects])
dnl @synopsis TRY_CFLAGS [compiler flags]
dnl @summary check whether compiler supports given flags and adds them to CFLAGS

8
src/CMakeLists.txt

@ -645,20 +645,20 @@ add_and_install_library(mod_webdav mod_webdav.c)
add_and_install_library(mod_wstunnel mod_wstunnel.c)
add_executable(test_buffer
test_buffer.c
t/test_buffer.c
buffer.c
)
add_test(NAME test_buffer COMMAND test_buffer)
add_executable(test_base64
test_base64.c
t/test_base64.c
buffer.c
base64.c
)
add_test(NAME test_base64 COMMAND test_base64)
add_executable(test_configfile
test_configfile.c
t/test_configfile.c
buffer.c
array.c
data_config.c
@ -671,7 +671,7 @@ add_executable(test_configfile
add_test(NAME test_configfile COMMAND test_configfile)
add_executable(test_request
test_request.c
t/test_request.c
request.c
buffer.c
array.c

26
src/Makefile.am

@ -1,14 +1,14 @@
AM_CFLAGS = $(FAM_CFLAGS) $(LIBUNWIND_CFLAGS)
noinst_PROGRAMS=test_buffer test_base64 test_configfile test_request
noinst_PROGRAMS=t/test_buffer t/test_base64 t/test_configfile t/test_request
sbin_PROGRAMS=lighttpd lighttpd-angel
LEMON=$(top_builddir)/src/lemon$(BUILD_EXEEXT)
TESTS=\
test_buffer$(EXEEXT) \
test_base64$(EXEEXT) \
test_configfile$(EXEEXT) \
test_request$(EXEEXT)
t/test_buffer$(EXEEXT) \
t/test_base64$(EXEEXT) \
t/test_configfile$(EXEEXT) \
t/test_request$(EXEEXT)
lemon$(BUILD_EXEEXT): lemon.c
$(AM_V_CC)$(CC_FOR_BUILD) $(CPPFLAGS_FOR_BUILD) $(CFLAGS_FOR_BUILD) $(LDFLAGS_FOR_BUILD) -o $@ $(srcdir)/lemon.c
@ -511,17 +511,17 @@ lighttpd_LDFLAGS = -export-dynamic
endif
test_buffer_SOURCES = test_buffer.c buffer.c
test_buffer_LDADD = $(LIBUNWIND_LIBS)
t_test_buffer_SOURCES = t/test_buffer.c buffer.c
t_test_buffer_LDADD = $(LIBUNWIND_LIBS)
test_base64_SOURCES = test_base64.c base64.c buffer.c
test_base64_LDADD = $(LIBUNWIND_LIBS)
t_test_base64_SOURCES = t/test_base64.c base64.c buffer.c
t_test_base64_LDADD = $(LIBUNWIND_LIBS)
test_configfile_SOURCES = test_configfile.c buffer.c array.c data_config.c data_string.c http_kv.c vector.c log.c sock_addr.c
test_configfile_LDADD = $(PCRE_LIB) $(LIBUNWIND_LIBS)
t_test_configfile_SOURCES = t/test_configfile.c buffer.c array.c data_config.c data_string.c http_kv.c vector.c log.c sock_addr.c
t_test_configfile_LDADD = $(PCRE_LIB) $(LIBUNWIND_LIBS)
test_request_SOURCES = test_request.c request.c buffer.c array.c data_string.c http_kv.c log.c sock_addr.c
test_request_LDADD = $(LIBUNWIND_LIBS)
t_test_request_SOURCES = t/test_request.c request.c buffer.c array.c data_string.c http_kv.c log.c sock_addr.c
t_test_request_LDADD = $(LIBUNWIND_LIBS)
noinst_HEADERS = $(hdr)
EXTRA_DIST = \

8
src/meson.build

@ -687,20 +687,20 @@ executable('lighttpd', configparser,
)
test('test_buffer', executable('test_buffer',
sources: ['test_buffer.c', 'buffer.c'],
sources: ['t/test_buffer.c', 'buffer.c'],
dependencies: common_flags + libunwind,
build_by_default: false,
))
test('test_base64', executable('test_base64',
sources: ['test_base64.c', 'buffer.c', 'base64.c'],
sources: ['t/test_base64.c', 'buffer.c', 'base64.c'],
dependencies: common_flags + libunwind,
build_by_default: false,
))
test('test_configfile', executable('test_configfile',
sources: [
'test_configfile.c',
't/test_configfile.c',
'buffer.c',
'array.c',
'data_config.c',
@ -716,7 +716,7 @@ test('test_configfile', executable('test_configfile',
test('test_request', executable('test_request',
sources: [
'test_request.c',
't/test_request.c',
'request.c',
'buffer.c',
'array.c',

0
src/test_base64.c → src/t/test_base64.c

0
src/test_buffer.c → src/t/test_buffer.c

0
src/test_configfile.c → src/t/test_configfile.c

0
src/test_request.c → src/t/test_request.c

1
tests/CMakeLists.txt

@ -19,7 +19,6 @@ set(T_FILES
core-keepalive.t
core-request.t
core-response.t
core.t
core-var-include.t
lowercase.t
mod-access.t

Loading…
Cancel
Save