Skip to content
Switch branches/tags

Name already in use

A tag already exists with the provided branch name. Many Git commands accept both tag and branch names, so creating this branch may cause unexpected behavior. Are you sure you want to create this branch?
Go to file
Cannot retrieve contributors at this time
static void (*real_one) ();
static void stub(){}
/* in CheatSheetTest.cpp */
#include "CppUTest/TestHarness.h"
/* Declare TestGroup with name CheatSheet */
/* declare a setup method for the test group. Optional. */
void setup() _override
/* Set method real_one to stub. Automatically restore in teardown */
UT_PTR_SET(real_one, stub);
/* Declare a teardown method for the test group. Optional */
void teardown() _override
}; /* Do not forget semicolumn */
/* Declare one test within the test group */
TEST(CheatSheet, TestName)
/* Check two longs are equal */
/* Check a condition */
CHECK(true == true);
/* Check a string */
STRCMP_EQUAL("HelloWorld", "HelloWorld");