mirror of
https://github.com/unittest-cpp/unittest-cpp
synced 2026-09-27 00:28:49 +03:00
created simple test (not passing yet)
This commit is contained in:
parent
183209faf8
commit
e525453911
1 changed files with 38 additions and 0 deletions
38
tests/TestParameterizedTest.cpp
Normal file
38
tests/TestParameterizedTest.cpp
Normal file
|
|
@ -0,0 +1,38 @@
|
|||
#include "UnitTest++/UnitTest++.h"
|
||||
|
||||
#include <string>
|
||||
#include "UnitTest++/ParameterizedTest.h"
|
||||
|
||||
using namespace std;
|
||||
using namespace UnitTest;
|
||||
|
||||
SUITE(ParameterizedTest)
|
||||
{
|
||||
vector<string> voyelleValues;
|
||||
ParameterizedTest<string> voyelle(voyelleValues);
|
||||
|
||||
struct InitVoyelle
|
||||
{
|
||||
InitVoyelle()
|
||||
{
|
||||
voyelleValues.push_back("A");
|
||||
voyelleValues.push_back("E");
|
||||
voyelleValues.push_back("I");
|
||||
voyelleValues.push_back("O");
|
||||
voyelleValues.push_back("U");
|
||||
voyelleValues.push_back("Y");
|
||||
}
|
||||
} InitVoyelleInstance;
|
||||
|
||||
|
||||
static string buildVoyellesStringOutput;
|
||||
TEST(BuildVoyellesString)
|
||||
{
|
||||
buildVoyellesStringOutput += voyelle();
|
||||
}
|
||||
|
||||
TEST(CheckVoyelle)
|
||||
{
|
||||
CHECK_EQUAL("AEIOUY", buildVoyellesStringOutput);
|
||||
}
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue