Wire Sysio Wire Sysion 1.0.0
|
unit test class More...
#include <stdio.h>
#include <string.h>
#include <string>
#include <list>
#include <iostream>
#include <utility>
#include <stdint.h>
Go to the source code of this file.
Classes | |
class | cybozu::test::AutoRun |
Namespaces | |
namespace | cybozu |
namespace | cybozu::test |
Macros | |
#define | CYBOZU_TEST_ASSERT(x) |
#define | CYBOZU_TEST_EQUAL(x, y) |
#define | CYBOZU_TEST_NEAR(x, y, eps) |
#define | CYBOZU_TEST_EQUAL_POINTER(x, y) |
#define | CYBOZU_TEST_EQUAL_ARRAY(x, y, n) |
#define | CYBOZU_TEST_FAIL(msg) |
#define | CYBOZU_TEST_EXCEPTION_MESSAGE(statement, Exception, msg) |
#define | CYBOZU_TEST_EXCEPTION(statement, Exception) |
#define | CYBOZU_TEST_NO_EXCEPTION(statement) |
#define | CYBOZU_TEST_AUTO(name) |
#define | CYBOZU_TEST_AUTO_WITH_FIXTURE(name, Fixture) |
#define | CYBOZU_TEST_SETUP_FIXTURE(Fixture) |
Functions | |
void | cybozu::test::test (bool ret, const std::string &msg, const std::string ¶m, const char *file, int line) |
template<typename T , typename U > | |
bool | cybozu::test::isEqual (const T &lhs, const U &rhs) |
bool | cybozu::test::isEqual (size_t lhs, int rhs) |
bool | cybozu::test::isEqual (int lhs, size_t rhs) |
bool | cybozu::test::isEqual (const char *lhs, const char *rhs) |
bool | cybozu::test::isEqual (char *lhs, const char *rhs) |
bool | cybozu::test::isEqual (const char *lhs, char *rhs) |
bool | cybozu::test::isEqual (char *lhs, char *rhs) |
bool | cybozu::test::isEqual (float lhs, float rhs) |
bool | cybozu::test::isEqual (double lhs, double rhs) |
int | main (int argc, char *argv[]) |
Copyright (C) 2008 Cybozu Labs, Inc., all rights reserved.
Definition in file test.hpp.
#define CYBOZU_TEST_ASSERT | ( | x | ) |
alert if !x
x | [in] |
#define CYBOZU_TEST_AUTO | ( | name | ) |
append auto unit test
name | [in] module name |
Definition at line 324 of file test.hpp.
append auto unit test with fixture
name | [in] module name |
Definition at line 338 of file test.hpp.
#define CYBOZU_TEST_EQUAL | ( | x, | |
y ) |
alert if x != y
x | [in] |
y | [in] |
Definition at line 201 of file test.hpp.
#define CYBOZU_TEST_EQUAL_ARRAY | ( | x, | |
y, | |||
n ) |
alert if x[] != y[]
x | [in] |
y | [in] |
n | [in] |
Definition at line 237 of file test.hpp.
#define CYBOZU_TEST_EQUAL_POINTER | ( | x, | |
y ) |
Definition at line 223 of file test.hpp.
#define CYBOZU_TEST_EXCEPTION | ( | statement, | |
Exception ) |
Definition at line 287 of file test.hpp.
#define CYBOZU_TEST_EXCEPTION_MESSAGE | ( | statement, | |
Exception, | |||
msg ) |
verify message in exception
Definition at line 258 of file test.hpp.
#define CYBOZU_TEST_FAIL | ( | msg | ) |
always alert
msg | [in] |
#define CYBOZU_TEST_NEAR | ( | x, | |
y, | |||
eps ) |
alert if fabs(x, y) >= eps
x | [in] |
y | [in] |
Definition at line 214 of file test.hpp.
#define CYBOZU_TEST_NO_EXCEPTION | ( | statement | ) |
verify statement does not throw
Definition at line 312 of file test.hpp.
#define CYBOZU_TEST_SETUP_FIXTURE | ( | Fixture | ) |
setup fixture
Fixture | [in] class name of fixture |
Definition at line 358 of file test.hpp.