Changeset 0fce81


Ignore:
Timestamp:
Apr 6, 2011, 4:05:13 PM (15 years ago)
Author:
Frederik Heber <heber@…>
Children:
d2023c
Parents:
09305f
git-author:
Frederik Heber <heber@…> (04/06/11 12:16:30)
git-committer:
Frederik Heber <heber@…> (04/06/11 16:05:13)
Message:

Moved unittests to Helpers/unittests, split off TestRunner into new unittests.

  • Unit tests should reside in a subdir of where the components to test reside in.
  • everything common to all unit tests resides in a specific unittests subdir of the src folder.
  • for now, SUBDIRS directive for Helpers/unittests and Patterns/unittests resides in ./ and not in src/Makefile.am to assure that libCodePatterns is compiled before. We need to re-structure the unit tests to not relie in the lib itself anymore but just on components and stubs.
Files:
1 added
3 edited
12 moved

Legend:

Unmodified
Added
Removed
  • Makefile.am

    r09305f r0fce81  
    11ACLOCAL_AMFLAGS = -I m4
    2 SUBDIRS = src src/unittests doc
     2SUBDIRS = src src/Helpers/unittests src/Patterns/unittests src/unittests doc
    33
    44AUTOMAKE_OPTIONS = subdir-objects
  • configure.ac

    r09305f r0fce81  
    5959        ])
    6060AC_CONFIG_FILES([
     61        src/unittests/Makefile
     62        src/Helpers/unittests/Makefile
    6163        src/Patterns/unittests/Makefile
    62         src/unittests/Makefile
    6364        ])
    6465AC_OUTPUT
  • src/unittests/Makefile.am

    r09305f r0fce81  
    11# PLEASE adhere to the alphabetical ordering in this Makefile!
    22# Also indentation by a single tab
    3 
    4 SUBDIRS = \
    5         ../Patterns/unittests
    63
    74INCLUDES = -I$(top_srcdir)/src/Patterns -I$(top_srcdir)/src/Helpers
     
    118AM_CPPFLAGS = ${BOOST_CPPFLAGS}
    129
    13 TESTS = \
    14         AssertUnitTest \
    15         ChronosUnitTest \
    16   InfoUnitTest \
    17   IteratorAdaptorsUnitTest \
    18   LogUnitTest \
    19   RangeUnitTest
    20 
    21 check_PROGRAMS = $(TESTS)
    22 noinst_PROGRAMS = $(TESTS) TestRunner
     10check_PROGRAMS = 
     11noinst_PROGRAMS = TestRunner
    2312
    2413BOOST_LIB = $(BOOST_MPL_LIB) $(BOOST_PROGRAM_OPTIONS_LIB) $(BOOST_FILESYSTEM_LIB) $(BOOST_SYSTEM_LIB) $(BOOST_THREAD_LIB)
     
    2817
    2918TESTSOURCES = \
     19  $(top_srcdir)/src/Helpers/unittests/AssertUnitTest.cpp \
     20  $(top_srcdir)/src/Helpers/unittests/ChronosUnitTest.cpp \
     21  $(top_srcdir)/src/Helpers/unittests/InfoUnitTest.cpp \
     22  $(top_srcdir)/src/Helpers/unittests/LogUnitTest.cpp \
     23  $(top_srcdir)/src/Helpers/unittests/RangeUnitTest.cpp \
    3024  $(top_srcdir)/src/Patterns/unittests/CacheableUnitTest.cpp \
    3125  $(top_srcdir)/src/Patterns/unittests/CloneUnitTest.cpp \
     
    4640  $(top_srcdir)/src/Patterns/unittests/stubs/ObserverStub.cpp \
    4741  $(top_srcdir)/src/Patterns/unittests/stubs/PrototypeFactoryStub.cpp \
    48   $(top_srcdir)/src/Patterns/unittests/stubs/RegistryStub.cpp \
    49   AssertUnitTest.cpp \
    50         ChronosUnitTest.cpp \
    51   InfoUnitTest.cpp \
    52   LogUnitTest.cpp \
    53   RangeUnitTest.cpp
     42  $(top_srcdir)/src/Patterns/unittests/stubs/RegistryStub.cpp
    5443
    5544TESTHEADERS = \
     45  $(top_srcdir)/src/Helpers/unittests/AssertUnitTest.hpp \
     46  $(top_srcdir)/src/Helpers/unittests/ChronosUnitTest.hpp \
     47  $(top_srcdir)/src/Helpers/unittests/InfoUnitTest.hpp \
     48  $(top_srcdir)/src/Helpers/unittests/LogUnitTest.hpp \
     49  $(top_srcdir)/src/Helpers/unittests/RangeUnitTest.hpp \
    5650  $(top_srcdir)/src/Patterns/unittests/CacheableUnitTest.hpp \
    5751  $(top_srcdir)/src/Patterns/unittests/CloneUnitTest.hpp \
     
    8074  $(top_srcdir)/src/Patterns/unittests/stubs/PrototypeFactoryStub.def \
    8175  $(top_srcdir)/src/Patterns/unittests/stubs/PrototypeFactoryStub.undef \
    82   $(top_srcdir)/src/Patterns/unittests/stubs/RegistryStub.hpp \
    83   AssertUnitTest.hpp \
    84         ChronosUnitTest.hpp \
    85   InfoUnitTest.hpp \
    86   LogUnitTest.hpp \
    87   RangeUnitTest.hpp
     76  $(top_srcdir)/src/Patterns/unittests/stubs/RegistryStub.hpp
    8877       
    89 
    90 AssertUnitTest_SOURCES = $(top_srcdir)/src/unittests/UnitTestMain.cpp \
    91         AssertUnitTest.cpp \
    92         AssertUnitTest.hpp
    93 AssertUnitTest_LDADD = ${TESTLIBS}
    94 
    95 ChronosUnitTest_SOURCES = $(top_srcdir)/src/unittests/UnitTestMain.cpp \
    96         ChronosUnitTest.cpp \
    97         ChronosUnitTest.hpp
    98 ChronosUnitTest_LDADD = ${TESTLIBS}
    99 
    100 InfoUnitTest_SOURCES = $(top_srcdir)/src/unittests/UnitTestMain.cpp \
    101         InfoUnitTest.cpp \
    102         InfoUnitTest.hpp
    103 InfoUnitTest_LDADD = ${TESTLIBS}
    104 
    105 IteratorAdaptorsUnitTest_SOURCES = $(top_srcdir)/src/unittests/UnitTestMain.cpp \
    106         IteratorAdaptorsUnitTest.cpp \
    107         $(top_srcdir)/src/Helpers/IteratorAdaptors.hpp \
    108         IteratorAdaptorsUnitTest.hpp
    109 #IteratorAdaptorsUnitTest_LDADD = ${TESTLIBS}
    110 
    111 LogUnitTest_SOURCES = $(top_srcdir)/src/unittests/UnitTestMain.cpp \
    112         LogUnitTest.cpp \
    113         LogUnitTest.hpp
    114 LogUnitTest_LDADD = ${TESTLIBS}
    115 
    116 RangeUnitTest_SOURCES = $(top_srcdir)/src/unittests/UnitTestMain.cpp \
    117         RangeUnitTest.cpp \
    118         RangeUnitTest.hpp
    119 #RangeUnitTest_LDADD = ${TESTLIBS}
    120 
    12178TestRunner_SOURCES = TestRunnerMain.cpp \
    12279        $(TESTSOURCES) \
Note: See TracChangeset for help on using the changeset viewer.