| Commit message (Collapse) | Author | Age | Files | Lines |
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
include/cppunit/Exception.h:
* src/cppunit/Exception.h: added setMessage().
* include/cppunit/Protector.h:
* src/cppunit/Protector.cpp: added class ProtectorGuard. Change the
reportXXX() method to support Exception passing and SourceLine.
* include/cppunit/TestCaller.h: removed 'expect exception' features.
It is now handled by ExceptionTestCaseDecorator and TestCaller no
longer need default template argument support.
* include/cppunit/TestCase.h:
* include/cppunit/extensions/TestCaller.h: runTest() is now public
instead of protected, so that it can be decorated.
* include/cppunit/TestResult.h:
* src/cppunit/TestResult.h: added pushProtector() and popProtector()
methods. This allow user to specify their own exception trap when
running test case.
* include/cppunit/extensions/TestDecorator.h:
* src/cppunit/TestDecorator.cpp: added. Extracted from TestDecorator.h.
The test passed to the constructor is now owned by the decorator.
* include/cppunit/extensions/TestCaseDecorator.h:
* src/cppunit/TestCaseDecorator.cpp: added. Decorator for TestCase
setUp(), tearDown() and runTest().
* include/cppunit/extensions/ExceptionTestCaseDecorator.h: added.
TestCaseDecorator to expect that a specific exception is thrown.
* include/cppunit/extensions/HelperMacros.h: updated against TestCaller
change.
* src/cppunit/DefaultFunctor.h: fixed bug (did not return underlying
test return code).
* src/cppunit/ProtectorChain.cpp: fixed bug in chaing return code.
* src/cppunit/DefaultFunctor.h: fixed bug.
* src/msvc6/testrunner/ActiveTest.h:
* src/msvc6/testrunner/ActiveTest.cpp: updated against
TestCaseDecorator ownership policy change. Moved inline functions
to .cpp.
* examples/cppunittest/TestSetUpTest.cpp: updated to use MockTestCase
and against the new ownership policy.
* examples/cppunittest/TestDecoratorTest.cpp:
* examples/cppunittest/RepeatedTestTest.cpp: updated against
TestDecorator ownership policy change.
* examples/cppunittest/ExceptionTestCaseDecoratorTest.h:
* examples/cppunittest/ExceptionTestCaseDecoratorTest.cpp: added. Unit
tests for ExceptionTestCaseDecoratorTest.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
CodingGuideLines.txt: added. CppUnit's coding guidelines for portability.
* include/cppunit/portability/CppUnitStack.h: added. wrapper for std::stack.
* include/cppunit/portability/CppUnitSet.h: added. wrapper for std::set.
* include/cppunit/ui/text/TestRunner.h: fixed namespace definition for
deprecated TestRunner.
* include/cppunit/TestAssert.h:
* src/cppunit/TestAssert.cpp: removed old deprecated functions that did
not use SourceLine. Moved assertEquals() and assertDoubleEquals() into
CppUnit namespace.
* src/cppunit/TestFactoryRegistry.cpp: use CppUnitMap instead of std::map.
* src/DllPlugInTester/CommandLineParser.h: use CppUnitDeque instead
std::deque.
* examples/cppunittest/*.h:
* examples/cppunittest/*.cpp: removed all usage of CppUnitTest namespace.
Everything is now in global space.
* examples/*/*.h:
* examples/*/*.cpp: replaced usage of CppUnit:: with CPPUNIT_NS::.
* examples/ClockerPlugIn/ClockerModel.h: use CppUnit STL wrapper instead
of STL container.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
include/cppunit/ui/text/TestRunner.h:
* src/cppunit/TextTestRunner.cpp: Renamed TextUi::TestRunner
TextTestRunner and moved it to the CppUnit namespace. Added
a deprecated typedef for compatibility with previous version.
* include/cppunit/ui/text/TextTestRunner.h: added.
* include/cppunit/ui/mfc/TestRunner.h:
* src/cppunit/msvc6/testrunner/TestRunner.cpp: Renamed MfcUi::TestRunner
MfcTestRunner. Added deprecated typedef for compatibility. Renamed
TestRunner.cpp to MfcTestRunner.cpp.
* include/cppunit/ui/mfc/MfcTestRunner.h: added.
* include/cppunit/ui/qt/TestRunner.h:
* src/qttestrunner/TestRunner.cpp: renamed QtUi::TestRunner QtTestRunner
and moved it to CppUnit namespace. Added a deprecated typedef for
compatibility. Renamed TestRunner.cpp to QtTestRunner.cpp.
* include/cppunit/ui/qt/TestRunner.h:
* src/qttestrunner/TestRunner.h: Moved TestRunner to CppUnit namespace
and renamed it QtTestRunner. Added deprecated typedef for compatibility.
* include/cppunit/Asserter.h:
* src/cppunit/Asserter.cpp: changed namespace Asserter to a struct and
made all methods static.
* include/cppunit/extensions/HelperMacros.h:
* include/cppunit/extensions/SourceLine.h:
* include/cppunit/extensions/TestAssert.h:
* include/cppunit/extensions/TestPlugIn.h:
* include/cppunit/Portability.h: changed CPPUNIT_NS(symbol) to a
symbol macro that expand either to CppUnit or nothing. The symbol is
no longer a parameter.
* include/cppunit/portability/CppUnitVector.h:
* include/cppunit/portability/CppUnitDeque.h:
* include/cppunit/portability/CppUnitMap.h: added. STL Wrapper for
compilers that do not support template default argumenent and need
the allocator to be passed when instantiating STL container.
* examples/cppunittest/*.h:
* examples/cppunittest/*.cpp:
* src/msvc6/testrunner/*.h:
* src/msvc6/testrunner/*.cpp:
* src/msvc6/testpluginrunner/*.h:
* src/msvc6/testpluginrunner/*.cpp:
* src/qttestrunner/*.h:
* src/qttestrunner/*.cpp: replaced occurence of CppUnit:: by CPPUNIT_NS.
* src/cppunit/TestSuite.h:
replaced occurence of std::vector by CppUnitVector.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
include/cppunit/Asserter.h:
* src/cppunit/Asserter.cpp: added functions that take a Message as a
parameter. Existing function have a short description indicating
an assertion failure.
* include/cppunit/CompilerOuputter.h:
* src/cppunit/CompilerOuputter.cpp: removed printNotEqualMessage() and
printDefaultMessage(). Updated to use Message.
* include/cppunit/Message.h:
* src/cppunit/Message.cpp: added. Represents a message associated to an
Exception.
* include/cppunit/Exception.h:
* src/cppunit/Exception.cpp: the message associated to the exception is now
stored as a Message instead of a string.
* include/cppunit/NotEqualException.cpp: constructs a Message instead of a
string.
* include/cppunit/TestAssert.h:
* src/cppunit/TestAssert.cpp: updated to use Asserter functions that
take a message when pertinent (CPPUNIT_FAIL...).
* include/cppunit/TestCaller.h:
* src/cppunit/TestCaller.cpp: exception not caught failure has a better
short description.
* src/cppunit/TestCase.cpp: better short description when setUp() or
tearDown() fail.
* src/msvc6/testrunner/TestRunnerDlg.cpp: replace '\n' in failure message
with space.
* examples/cppunittest/ExceptionTest.cpp:
* examples/cppunittest/NotEqualExceptionTest.cpp:
* examples/cppunittest/TestCallerTest.cpp:
* examples/cppunittest/TestFailureTest.cpp:
* examples/cppunittest/TestResultCollectorTest.h:
* examples/cppunittest/TestResultCollectorTest.cpp:
* examples/cppunittest/TestResultTest.cpp:
* examples/cppunittest/XmlOutputterTest.h:
* examples/cppunittest/XmlOutputterTest.cpp: updated to use Exception/Message.
* examples/cppunittest/MessageTest.h:
* examples/cppunittest/MessageTest.cpp: added. Unit test for Message.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
NEW: updated and restructured.
* include/cppunit/CompilerOutputter.h:
* src/cppunit/CompilerOutputter.cpp:
updated against TestResultChange. Changed TestResult to TestResultCollector.
* include/cppunit/extensions/HelperMacros.h: minor documentation fix.
* include/cppunit/Outputter.h: added. Abstract base class for all Outputter.
* include/cppunit/Portability.h: made the fix on OStringStream suggested by
Bob Summerwill to remove level 4 warning with VC++.
* include/cppunit/TestAssert.h: added macro CPPUNIT_ASSERT_EQUAL_MESSAGE.
* src/cppunit/TestFailure.cpp:
* include/cppunit/TestFailure.h: added method clone() to duplicate a failure. Made
all method virtual.
* include/cppunit/TestListener.h: changed signature of addFailure() to
addFailure( const TestFailure &failure ). Failure is now only a temporary object.
* include/cppunit/Outputter.h: added. Abstract base class for all outputter. Used
by TextTestRunner.
* include/cppunit/SynchronizedObject.h:
* src/cppunit/SynchronizedObject.cpp: added. Class extracted from TestResult.
Base class for objects that can be accessed from different threads.
* include/cppunit/TestResult.h: TestFailure.h is no longer included.
* include/cppunit/TestResult.h:
* src/cppunit/TestResult.cpp: extracted all methods related to keeping track
of the result to the new TestResultCollector class which is a TestListener.
* include/cppunit/TestResultCollector.h:
* src/cppunit/TestResultCollector.cpp: added. TestListener which kept track
of the result of the test run. All failure/error, and tests are tracked.
* include/cppunit/TestSucessListener.h:
* src/cppunit/TestSucessListener.cpp: added. TestListener extracted from
TestResult. Is responsible for wasSucessful().
* include/cppunit/TestCase.h:
* src/cppunit/TestCase.cpp: reindented.
* include/cppunit/TextOutputter.h:
* src/cppunit/TextOutputter.cpp: added. Copied from the deprecated
TextTestResult and modified to act as an Ouputter.
* include/cppunit/TextTestProgressListener.h:
* src/cppunit/TextTestProgressListener.cpp: Copied from the deprecated
TextTestResult and modified to print the dot while the test are running.
* include/cppunit/TextTestResult.h:
* src/cppunit/TextTestResult.cpp: updated against TestResult change.
No compatiblity break. Deprecated.
* include/cppunit/TextTestRunner.h:
* src/cppunit/TextTestRunner.cpp: updated to work with the new TestResult.
Use TextTestProgressListener and TextOutputter instead of TextTestResult.
Any outputter with interface Outputter can be used to print the test result
(CompilerOutputter, XmlOutputter, TextOutputter...)
* include/cppunit/XmlOutputter.h:
* src/cppunit/XmlOutputter.cpp: updated against TestResultChange.
Changed TestResult to TestResultCollector.
* src/msvc6/TestRunnerDlg.h:
* src/msvc6/TestRunnerDlg.cpp: fixed the 'fullrowselect' feature of the list view.
The dialog is a TestListener itself, it no longer use the GUITestResult class.
* src/msvc6/TestRunner.rc: moved the "autorun test button" in such a way that it
did not overlap the progress bar anymore.
* src/msvc6/MfcSynchronizationObject.h: added. Generic SynchronizedObject
lock for MFC.
* src/msvc6/GUITestResult.h :
* src/msvc6/GUITestResult.cpp : removed.
* src/qttestrunner/TestRunnerModel.h:
* src/qttestrunner/TestRunnerModel.cpp: changed addFailure() signature to reflect
change on TestListener.
* examples/cppunittest/CppUnitTestMain.cpp: updated to use the new Outputter
abstraction and TextTestRunner facilities.
* examples/cppunittest/FailingTestCase.h:
* examples/cppunittest/FailingTestCase.cpp: removed. Replaced by MockTestCase.
* examples/cppunittest/FailingTestCase.h:
* examples/cppunittest/FailingTestCase.h:
* examples/cppunittest/HelperMacrosTest.h:
* examples/cppunittest/HelperMacrosTest.cpp: Updated against TestResult change.
Use MockTestListener instead of TestResult to check for sucess or failure.
* examples/cppunittest/MockTestListener.h:
* examples/cppunittest/MockTestListener.cpp: the class now behave like a mock
object.
* examples/cppunittest/MockTestCase.h:
* examples/cppunittest/MockTestCase.cpp: added. Mock TestCase object.
* examples/cppunittest/OrthodoxTest.h:
* examples/cppunittest/OrthodoxTest.cpp: Updated against TestResult change.
Use MockTestListener instead of TestResult to check for sucess or failure.
* examples/cppunittest/SynchronizedTestResult.h: Updated against TestResult
change.
* examples/cppunittest/TestCallerTest.h:
* examples/cppunittest/TestCallerTest.cpp: Updated against TestResult change.
Use MockTestListener instead of TestResult.
* examples/cppunittest/TestCaseTest.h:
* examples/cppunittest/TestCaseTest.cpp: Updated against TestResult change.
Use MockTestListener and MockTestCase instead of FailingTestCase and TestResult.
* examples/cppunittest/TestDecoratorTest.h:
* examples/cppunittest/TestDecoratorTest.cpp: Updated against TestResult change.
Use MockTestCase instead of FailingTestCase.
* examples/cppunittest/TestListenerTest.h:
* examples/cppunittest/TestListenerTest.cpp: removed. Those unit tests have been
rewrote and moved to TestResultTest.
* examples/cppunittest/TestResultTest.h:
* examples/cppunittest/TestResultTest.cpp: Updated to test the new interface.
Tests from TestListenerTest have been moved here.
* examples/cppunittest/TestResultCollectorTest.h:
* examples/cppunittest/TestResultCollectorTest.cpp: added. Tests for the class
that been extracted from TestResult.
* examples/cppunittest/TestSetUpTest.h:
* examples/cppunittest/TestSetUpTest.cpp: renamed SetUp inner class to MockSetUp.
Changed interface to be more akin to a Mock object.
* examples/cppunittest/TestSuiteTest.h:
* examples/cppunittest/TestSuiteTest.cpp: Updated against TestResult change,
and rewrote to use MockTestCase instead of FailingTestCase.
* examples/cppunittest/XmlOutputterTest.h:
* examples/cppunittest/XmlOutputterTest.cpp: Updated against TestResult change.
Added some utility methods to make the update easier.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
include/cppunit/extensions/TestFactoryRegistry.h
* src/cppunit/TestFactoryRegistry.cpp : fixed memory leaks that
occured when a TestFactoryRegistry was registered into another
TestFactoryRegistry.
* include/cppunit/extensions/AutoRegisterSuite.h : updated doc.
* include/cppunit/extensions/HelperMacros.h : added macro
CPPUNIT_TEST_SUITE_NAMED_REGISTRATION to register a suite into
a named suite. Updated doc.
* examples/cppunittest/CoreSuite.h:
* examples/cppunittest/ExtensionSuite.h:
* examples/cppunittest/HelperSuite.h: added, declaration of suite for
use with CPPUNIT_TEST_SUITE_NAMED_REGISTRATION.
* examples/cppunittest/makefile.am : added HelperSuite.h, CoreSuite.h,
ExtensionSuite.h, CppUnitTestSuite.h and CppUnitTestSuite.cpp.
* examples/cppunittest/CppUnitTestSuite.*: added.
* examples/cppunittest/ExceptionTest.cpp:
* examples/cppunittest/TestAssertTest.cpp:
* examples/cppunittest/TestCaseTest.cpp:
* examples/cppunittest/TestFailureTest.cpp:
* examples/cppunittest/TestListenerTest.cpp:
* examples/cppunittest/TestResultTest.cpp:
* examples/cppunittest/TestSuiteTest.cpp: moved into named suite
"Core" using CPPUNIT_TEST_SUITE_NAMED_REGISTRATION.
* examples/cppunittest/OrthodoxTest.cpp:
* examples/cppunittest/RepeatedTest.cpp:
* examples/cppunittest/TestDecoratorTest.cpp:
* examples/cppunittest/TestSetUpTest.cpp: moved into named suite
"Extension" using CPPUNIT_TEST_SUITE_NAMED_REGISTRATION.
* examples/cppunittest/HelperMacrosTest.cpp:
* examples/cppunittest/TestCallerTest.cpp: moved into named suite
"Helper" using CPPUNIT_TEST_SUITE_NAMED_REGISTRATION.
* examples/cppunittest/CppUnitTest.dsp :
* examples/msvc6/CppUnitTestApp/CppUnitTestApp.dsp : added
Makefile.am, HelperSuite.h, CoreSuite.h, ExtensionSuite.h,
CppUnitTestSuite.h and CppUnitTestSuite.cpp.
|
|
|
|
|
|
| |
example/cppunittest/TestCaller.*: remove some memory leaks.
TestCaller exception catching features is now tested correctly.
Previous test tested nothing!
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Makefile.am: Added INSTALL-WIN32.txt to EXTRA_DIST.
* INSTALL-WIN32.txt: added, short documentation for CppUnit and VC++.
* include/cppunit/extensions/HelperMacros.h: bug #448363, removed
an extraneous ';' at the end of CPPUNIT_TEST_SUITE_END macro.
* examples/cppunittest/TestCallerTest.cpp: bug #448332, fixed
memory leaks.
* src/msvc6/testrunner/TestRunnerDlg.h:
* src/msvc6/testpluginrunner/TestPlugInRunnerDlg.h:
* src/msvc6/testpluginrunner/TestPlugInRunnerDlg.cpp: change to define
IDD to a dummy value when subclassing the dialog.
* src/cppunit/cppunit.dsp:
* src/msvc6/testrunner/TestRunner.dsp:
* src/msvc6/testpluginrunner/TestPlugInRunner.dsp:
* examples/cppunitttest/CppUnitTestMain.dsp:
* examples/hierarchy.dsp:
* examples/msvc6/TestPlugIn/TestPlugIn.dsp:
* examples/msvc6/HostApp/HostApp.dsp: all configurations can be compiled.
* src/msvc6/testpluginrunner/TestPlugInRunner.dsw: added dependency to
cppunit.dsp and TestRunner.dsp.
|
|
|
|
|
|
|
|
|
| |
examples/cppunittest/TestResultTest.*: renamed TestListenerTest.*
* examples/cppunittest/*: added unit tests for:
HelperMacros, TestAssert, TestCaller, TestCase, TestFailure,
TestResult, TestSuite, TestDecoratorTest, TestSetUp, RepeatedTestTest,
Orthodox, Exception.
|
|
|
|
| |
macros
|
| |
|
|
|
|
|
|
| |
function to form a pointer to member function' bug reported by g++.
(suite): removed dependency on RTTI.
|
|
added project cppunittest to examples/: unit tests to test cppunit. The
main file is CppUnitTestMain.cpp. Unit tests have been implemented
for TestCaller and TestListener.
* added project CppUnitTestApp to examples/msvc6: graphical runner for
cppunittest.
* added TestListener to TestResult. It is a port of junit TestListener.
* updated some .cvsignore to ignore files generated with VC++.
|