2006-09-14 19:06:51 +02:00
|
|
|
# Copyright (C) 2006 MySQL AB & MySQL Finland AB & TCX DataKonsult AB
|
WL#3234 Maria control file manager.
Fitting ma_control_file_test into the mytap unittest framework:
new directories:
- unittest/storage/ for unit tests of any storage engine
- unittest/storage/maria for ... Maria, containing ma_control_file-t.
Later, older tests like ma_test*, ma_test_all (but which is Unix
dependent in its current form) could move here too.
The plugins macro enable building of unittest/storage/X for any
enabled engine X which has such a directory.
If Falcon wants to have unit tests there too, I may have to merge
this patch into 5.x one day.
config/ac-macros/plugins.m4:
If a storage engine has a directory in unittest/storage, build this
directory.
configure.in:
build storage engines' unit tests.
storage/maria/Makefile.am:
ma_control_file_test moves to unittest/storage/maria
storage/maria/ma_control_file.c:
more error codes when opening the control file fails.
ma_control_file_end() may now return an error if my_close() failed.
storage/maria/ma_control_file.h:
more error codes when opening the control file fails.
unittest/Makefile.am:
adding unit tests for storage engines.
Note that unit.pl simply recurses into "storage", so if a unit test for
storage engine X has been built previously, and now you re-configure
(without making clean) to disable this engine, then the unit test of
X will not be rebuilt but will still be present in storage/X, so will
be run.
unittest/storage/maria/ma_control_file-t.c:
Making the test fit the mytap framework (return all the way up
the stack instead of assert(); use the mytap functions plan(), ok() etc).
Adding test of file too short/long.
unittest/storage/maria/Makefile.am:
a_control_file-t is added to the Maria unit tests.
Later, older tests (ma_test1 etc) could also move here.
unittest/storage/Makefile.am:
New BitKeeper file ``unittest/storage/Makefile.am''
2006-09-11 16:12:31 +02:00
|
|
|
#
|
|
|
|
# This program is free software; you can redistribute it and/or modify
|
|
|
|
# it under the terms of the GNU General Public License as published by
|
|
|
|
# the Free Software Foundation; either version 2 of the License, or
|
|
|
|
# (at your option) any later version.
|
|
|
|
#
|
|
|
|
# This program is distributed in the hope that it will be useful,
|
|
|
|
# but WITHOUT ANY WARRANTY; without even the implied warranty of
|
|
|
|
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
|
|
|
# GNU General Public License for more details.
|
|
|
|
#
|
|
|
|
# You should have received a copy of the GNU General Public License
|
|
|
|
# along with this program; if not, write to the Free Software
|
|
|
|
# Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
|
|
|
|
|
2007-02-02 09:41:32 +02:00
|
|
|
AM_CPPFLAGS = @ZLIB_INCLUDES@ -I$(top_builddir)/include \
|
|
|
|
-I$(top_srcdir)/include -I$(top_srcdir)/unittest/mytap
|
|
|
|
INCLUDES = @ZLIB_INCLUDES@ -I$(top_builddir)/include \
|
|
|
|
-I$(top_srcdir)/include -I$(top_srcdir)/unittest/mytap
|
WL#3234 Maria control file manager.
Fitting ma_control_file_test into the mytap unittest framework:
new directories:
- unittest/storage/ for unit tests of any storage engine
- unittest/storage/maria for ... Maria, containing ma_control_file-t.
Later, older tests like ma_test*, ma_test_all (but which is Unix
dependent in its current form) could move here too.
The plugins macro enable building of unittest/storage/X for any
enabled engine X which has such a directory.
If Falcon wants to have unit tests there too, I may have to merge
this patch into 5.x one day.
config/ac-macros/plugins.m4:
If a storage engine has a directory in unittest/storage, build this
directory.
configure.in:
build storage engines' unit tests.
storage/maria/Makefile.am:
ma_control_file_test moves to unittest/storage/maria
storage/maria/ma_control_file.c:
more error codes when opening the control file fails.
ma_control_file_end() may now return an error if my_close() failed.
storage/maria/ma_control_file.h:
more error codes when opening the control file fails.
unittest/Makefile.am:
adding unit tests for storage engines.
Note that unit.pl simply recurses into "storage", so if a unit test for
storage engine X has been built previously, and now you re-configure
(without making clean) to disable this engine, then the unit test of
X will not be rebuilt but will still be present in storage/X, so will
be run.
unittest/storage/maria/ma_control_file-t.c:
Making the test fit the mytap framework (return all the way up
the stack instead of assert(); use the mytap functions plan(), ok() etc).
Adding test of file too short/long.
unittest/storage/maria/Makefile.am:
a_control_file-t is added to the Maria unit tests.
Later, older tests (ma_test1 etc) could also move here.
unittest/storage/Makefile.am:
New BitKeeper file ``unittest/storage/Makefile.am''
2006-09-11 16:12:31 +02:00
|
|
|
|
|
|
|
# Only reason to link with libmyisam.a here is that it's where some fulltext
|
|
|
|
# pieces are (but soon we'll remove fulltext dependencies from Maria).
|
|
|
|
LDADD= $(top_builddir)/unittest/mytap/libmytap.a \
|
|
|
|
$(top_builddir)/storage/maria/libmaria.a \
|
|
|
|
$(top_builddir)/storage/myisam/libmyisam.a \
|
|
|
|
$(top_builddir)/mysys/libmysys.a \
|
|
|
|
$(top_builddir)/dbug/libdbug.a \
|
2007-02-02 09:41:32 +02:00
|
|
|
$(top_builddir)/strings/libmystrings.a @ZLIB_LIBS@ \
|
|
|
|
$(top_builddir)/storage/maria/ma_loghandler.o
|
2007-02-02 13:55:48 +02:00
|
|
|
noinst_PROGRAMS = ma_control_file-t trnman-t lockman2-t \
|
2007-02-02 09:41:32 +02:00
|
|
|
mf_pagecache_single_1k-t mf_pagecache_single_8k-t \
|
2007-02-12 14:23:43 +02:00
|
|
|
mf_pagecache_single_64k-t-big \
|
|
|
|
mf_pagecache_consist_1k-t-big \
|
|
|
|
mf_pagecache_consist_64k-t-big \
|
|
|
|
mf_pagecache_consist_1kHC-t-big \
|
|
|
|
mf_pagecache_consist_64kHC-t-big \
|
|
|
|
mf_pagecache_consist_1kRD-t-big \
|
|
|
|
mf_pagecache_consist_64kRD-t-big \
|
|
|
|
mf_pagecache_consist_1kWR-t-big \
|
|
|
|
mf_pagecache_consist_64kWR-t-big \
|
2007-02-02 09:41:32 +02:00
|
|
|
ma_test_loghandler-t \
|
|
|
|
ma_test_loghandler_multigroup-t \
|
|
|
|
ma_test_loghandler_multithread-t \
|
|
|
|
ma_test_loghandler_pagecache-t
|
|
|
|
|
|
|
|
mf_pagecache_single_src = mf_pagecache_single.c $(top_srcdir)/mysys/mf_pagecache.c test_file.c
|
|
|
|
mf_pagecache_consist_src = mf_pagecache_consist.c $(top_srcdir)/mysys/mf_pagecache.c test_file.c
|
|
|
|
mf_pagecache_common_cppflags = -DEXTRA_DEBUG -DPAGECACHE_DEBUG -DMAIN
|
|
|
|
|
|
|
|
mf_pagecache_single_1k_t_SOURCES = $(mf_pagecache_single_src)
|
|
|
|
mf_pagecache_single_8k_t_SOURCES = $(mf_pagecache_single_src)
|
2007-02-12 14:23:43 +02:00
|
|
|
mf_pagecache_single_64k_t_big_SOURCES = $(mf_pagecache_single_src)
|
2007-02-02 09:41:32 +02:00
|
|
|
mf_pagecache_single_1k_t_CPPFLAGS = $(mf_pagecache_common_cppflags) -DPAGE_SIZE=1024
|
|
|
|
mf_pagecache_single_8k_t_CPPFLAGS = $(mf_pagecache_common_cppflags) -DPAGE_SIZE=8192
|
2007-02-12 14:23:43 +02:00
|
|
|
mf_pagecache_single_64k_t_big_CPPFLAGS = $(mf_pagecache_common_cppflags) -DPAGE_SIZE=65536
|
2007-02-02 09:41:32 +02:00
|
|
|
|
2007-02-12 14:23:43 +02:00
|
|
|
mf_pagecache_consist_1k_t_big_SOURCES = $(mf_pagecache_consist_src)
|
|
|
|
mf_pagecache_consist_1k_t_big_CPPFLAGS = $(mf_pagecache_common_cppflags) -DPAGE_SIZE=1024
|
|
|
|
mf_pagecache_consist_64k_t_big_SOURCES = $(mf_pagecache_consist_src)
|
|
|
|
mf_pagecache_consist_64k_t_big_CPPFLAGS = $(mf_pagecache_common_cppflags) -DPAGE_SIZE=65536
|
2007-02-02 09:41:32 +02:00
|
|
|
|
2007-02-12 14:23:43 +02:00
|
|
|
mf_pagecache_consist_1kHC_t_big_SOURCES = $(mf_pagecache_consist_src)
|
|
|
|
mf_pagecache_consist_1kHC_t_big_CPPFLAGS = $(mf_pagecache_common_cppflags) -DPAGE_SIZE=1024 -DTEST_HIGH_CONCURENCY
|
|
|
|
mf_pagecache_consist_64kHC_t_big_SOURCES = $(mf_pagecache_consist_src)
|
|
|
|
mf_pagecache_consist_64kHC_t_big_CPPFLAGS = $(mf_pagecache_common_cppflags) -DPAGE_SIZE=65536 -DTEST_HIGH_CONCURENCY
|
2007-02-02 09:41:32 +02:00
|
|
|
|
2007-02-12 14:23:43 +02:00
|
|
|
mf_pagecache_consist_1kRD_t_big_SOURCES = $(mf_pagecache_consist_src)
|
|
|
|
mf_pagecache_consist_1kRD_t_big_CPPFLAGS = $(mf_pagecache_common_cppflags) -DPAGE_SIZE=1024 -DTEST_READERS
|
|
|
|
mf_pagecache_consist_64kRD_t_big_SOURCES = $(mf_pagecache_consist_src)
|
|
|
|
mf_pagecache_consist_64kRD_t_big_CPPFLAGS = $(mf_pagecache_common_cppflags) -DPAGE_SIZE=65536 -DTEST_READERS
|
2007-02-02 09:41:32 +02:00
|
|
|
|
2007-02-12 14:23:43 +02:00
|
|
|
mf_pagecache_consist_1kWR_t_big_SOURCES = $(mf_pagecache_consist_src)
|
|
|
|
mf_pagecache_consist_1kWR_t_big_CPPFLAGS = $(mf_pagecache_common_cppflags) -DPAGE_SIZE=1024 -DTEST_WRITERS
|
|
|
|
mf_pagecache_consist_64kWR_t_big_SOURCES = $(mf_pagecache_consist_src)
|
|
|
|
mf_pagecache_consist_64kWR_t_big_CPPFLAGS = $(mf_pagecache_common_cppflags) -DPAGE_SIZE=65536 -DTEST_WRITERS
|
2007-02-02 09:41:32 +02:00
|
|
|
|
2006-11-30 15:12:28 +01:00
|
|
|
# the generic lock manager may not be used in the end and lockman1-t crashes,
|
|
|
|
# so we don't build lockman-t and lockman1-t
|
2007-02-02 09:41:32 +02:00
|
|
|
CLEANFILES = maria_control page_cache_test_file_1 \
|
2007-02-12 14:23:43 +02:00
|
|
|
maria_log.????????
|
2007-02-02 13:55:48 +02:00
|
|
|
|