Solved

creating Test suite in c++

Posted on 2013-02-06
3
417 Views
Last Modified: 2013-02-14
I need to create a simple Test Suite to run some test cases in C++, after googling and inspecting some open source ones i m still confused on how to create my assertions and how to output the results with failures and success rate.
I don't like to stop running tests when they fail but just output the result and continue.
Any help how to start this ?
0
Comment
Question by:bachra04
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
3 Comments
 
LVL 32

Expert Comment

by:phoffric
ID: 38861483
We used a variant of CPPUnit test in our project. Here's the first link when I googled "cppunit test":
   http://cppunit.sourceforge.net/doc/lastest/cppunit_cookbook.html
0
 
LVL 22

Assisted Solution

by:ambience
ambience earned 250 total points
ID: 38867012
I too use CppUnit, and for continuing even after failures you use this syntax

 CPPUT_IGNORE_FAILURE(( CPPUT_ASSERT_EQUAL( 1, 2 ) ));

This is described here: http://cppunit.sourceforge.net/cppunit2/doc/index.html#section_ignore_assertion_failure

The assertion failure is still logged
0
 
LVL 4

Accepted Solution

by:
havman56 earned 250 total points
ID: 38867511
Please google test  http://code.google.com/p/googletest/

gtest_exceptions =1 enable it

better than cppunit.
0

Featured Post

[Webinar] Code, Load, and Grow

Managing multiple websites, servers, applications, and security on a daily basis? Join us for a webinar on May 25th to learn how to simplify administration and management of virtual hosts for IT admins, create a secure environment, and deploy code more effectively and frequently.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

The purpose of this article is to fix the unknown display problem in Linux Mint operating system. After installing the OS if you see Display monitor is not recognized then we can install "MESA" utilities to fix this problem or we can install additio…
The purpose of this article is to demonstrate how we can upgrade Python from version 2.7.6 to Python 2.7.10 on the Linux Mint operating system. I am using an Oracle Virtual Box where I have installed Linux Mint operating system version 17.2. Once yo…
The goal of the video will be to teach the user the concept of local variables and scope. An example of a locally defined variable will be given as well as an explanation of what scope is in C++. The local variable and concept of scope will be relat…
The goal of the video will be to teach the user the difference and consequence of passing data by value vs passing data by reference in C++. An example of passing data by value as well as an example of passing data by reference will be be given. Bot…

738 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question