Commit 3f9e35d3 authored by unknown's avatar unknown
Browse files

WL#3206 (Adding unit tests):

Moving mytap library into unittest/
Adding 'test' target to make and run unit tests.
Minor fixes.


unittest/mytap/Doxyfile:
  mvdir
unittest/mytap/t/basic.t.c:
  mvdir
unittest/mytap/tap.c:
  mvdir
unittest/mytap/tap.h:
  mvdir
Makefile.am:
  Correcting after moving mytap/
configure.in:
  Correcting after moving mytap/
unittest/Makefile.am:
  Adding 'test' target to build and execute unit tests.
unittest/examples/Makefile.am:
  Correcting after moving mytap/
unittest/mysys/Makefile.am:
  Correcting after moving mytap/
unittest/mysys/bitmap.t.c:
  Adding copyright notice.
unittest/mytap/Makefile.am:
  Correcting after moving mytap/
unittest/mytap/t/Makefile.am:
  Correcting after moving mytap/
unittest/mysys/base64.t.c:
  New BitKeeper file ``unittest/mysys/base64.t.c''
parent b0d2b658
Loading
Loading
Loading
Loading
+2 −2
Original line number Diff line number Diff line
@@ -29,7 +29,7 @@ SUBDIRS = . include @docs_dirs@ @zlib_dir@ @yassl_dir@ \
			@mysql_se_plugins@ \
			netware @libmysqld_dirs@ \
			@bench_dirs@ support-files @tools_dirs@ \
			plugin mytap unittest
			plugin unittest

DIST_SUBDIRS =		. include @docs_dirs@ zlib \
			@readline_topdir@ sql-common \
@@ -39,7 +39,7 @@ DIST_SUBDIRS = . include @docs_dirs@ zlib \
			@man_dirs@ tests SSL\
			BUILD netware os2 @libmysqld_dirs@\
			@bench_dirs@ support-files server-tools tools \
			plugin mytap unittest
			plugin unittest

# Run these targets before any others, also make part of clean target,
# to make sure we create new links after a clean.
+2 −1
Original line number Diff line number Diff line
@@ -2599,7 +2599,8 @@ AC_SUBST(MAKE_BINARY_DISTRIBUTION_OPTIONS)

# Output results
AC_CONFIG_FILES(Makefile extra/Makefile mysys/Makefile dnl
 mytap/Makefile mytap/t/Makefile unittest/Makefile dnl
 unittest/Makefile dnl
 unittest/mytap/Makefile unittest/mytap/t/Makefile dnl
 unittest/mysys/Makefile unittest/examples/Makefile dnl
 strings/Makefile regex/Makefile storage/Makefile storage/heap/Makefile dnl
 storage/myisam/Makefile storage/myisammrg/Makefile dnl
+21 −1
Original line number Diff line number Diff line
SUBDIRS = mysys examples
SUBDIRS      = mytap . mysys examples

.PHONY: mytap mysys examples test

noinst_SCRIPTS = unit

test: mytap mysys examples
	./unit run $^

mytap:
	cd mytap && $(MAKE)

mysys:
	cd mysys && $(MAKE)

examples:
	cd examples && $(MAKE)

unit: unit.pl
	cp $< $@
	chmod +x $@
+3 −3
Original line number Diff line number Diff line
AM_CPPFLAGS        = -I$(srcdir) -I$(top_builddir)/include
AM_CPPFLAGS       += -I$(top_builddir)/mytap
AM_CPPFLAGS       += -I$(top_builddir)/unittest/mytap

AM_LDFLAGS         = -L$(top_builddir)/mytap
AM_LDFLAGS         = -L$(top_builddir)/unittest/mytap

AM_CFLAGS          = -Wall -ansi -pedantic
AM_CFLAGS          = -W -Wall -ansi -pedantic

LDADD              = -lmytap

+9 −8
Original line number Diff line number Diff line

AM_CPPFLAGS      = -I$(srcdir) -I$(top_builddir)/include
AM_CPPFLAGS     += -I$(top_builddir)/mytap
AM_CPPFLAGS      = @ZLIB_INCLUDES@ -I$(top_builddir)/include 
AM_CPPFLAGS     += -I$(top_srcdir)/include -I$(top_builddir)/unittest/mytap

AM_CFLAGS        = -Wall -ansi -pedantic
AM_LDFLAGS       = -L$(top_builddir)/unittest/mytap -L$(top_builddir)/mysys
AM_LDFLAGS      += -L$(top_builddir)/strings -L$(top_builddir)/dbug

AM_LDFLAGS       = -L$(top_builddir)/mytap -L$(top_builddir)/mysys
AM_LDFLAGS      += -L$(top_builddir)/strings
LDADD            = -lmytap -lmysys -lmystrings -ldbug

LDADD            = -lmytap -lmysys -lmystrings

noinst_PROGRAMS  = bitmap.t
noinst_PROGRAMS  = bitmap.t base64.t

bitmap_t_SOURCES = bitmap.t.c

base64_t_SOURCES = base64.t.c
Loading