wibble 1.1
singleton.test.h
Go to the documentation of this file.
1/* -*- C++ -*- (c) 2007 Petr Rockai <me@mornfall.net>
2 (c) 2007 Enrico Zini <enrico@enricozini.org> */
3
4#include <wibble/test.h>
5#include <wibble/singleton.h>
6
7namespace {
8
9using namespace std;
10using namespace wibble;
11
12struct TestSingleton {
13
14 Test simple() {
16
17 assert_eq(container.size(), 1u);
18
20 assert(!(i == container.end()));
21 assert(i != container.end());
22 assert_eq(*i, 5);
23
24 ++i;
25 assert(i == container.end());
26 assert(!(i != container.end()));
27 }
28
29};
30
31}
Definition singleton.h:60
Definition amorph.h:17
Singleton< T > singleton(const T &value)
Definition singleton.h:102
Definition amorph.h:30
#define assert_eq(x, y)
Definition test.h:33
#define assert(x)
Definition test.h:30